<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.5"/>
<title>MCUXpresso SDK API Reference Manual: I2C Driver</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<script type="text/javascript">
  $(document).ready(initResizable);
  $(window).load(resizeHeight);
</script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/javascript">
  $(document).ready(function() { searchBox.OnSelectItem(0); });
</script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<link href="customdoxygen.css" rel="stylesheet" type="text/css"/>
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectlogo"><img alt="Logo" src="fs_logo.gif"/></td>
  <td style="padding-left: 0.5em;">
   <div id="projectname">MCUXpresso SDK API Reference Manual
   &#160;<span id="projectnumber">Rev. 0</span>
   </div>
   <div id="projectbrief">NXP Semiconductors</div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.5 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Main&#160;Page</span></a></li>
      <li><a href="pages.html"><span>Related&#160;Pages</span></a></li>
      <li><a href="modules.html"><span>API&#160;Reference</span></a></li>
      <li>
        <div id="MSearchBox" class="MSearchBoxInactive">
        <span class="left">
          <img id="MSearchSelect" src="search/mag_sel.png"
               onmouseover="return searchBox.OnSearchSelectShow()"
               onmouseout="return searchBox.OnSearchSelectHide()"
               alt=""/>
          <input type="text" id="MSearchField" value="Search" accesskey="S"
               onfocus="searchBox.OnSearchFieldFocus(true)" 
               onblur="searchBox.OnSearchFieldFocus(false)" 
               onkeyup="searchBox.OnSearchFieldChange(event)"/>
          </span><span class="right">
            <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
          </span>
        </div>
      </li>
    </ul>
  </div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
$(document).ready(function(){initNavTree('group__i2c__driver.html','');});
</script>
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
<a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(0)"><span class="SelectionMark">&#160;</span>All</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark">&#160;</span>Data Structures</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark">&#160;</span>Functions</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(3)"><span class="SelectionMark">&#160;</span>Variables</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(4)"><span class="SelectionMark">&#160;</span>Typedefs</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(5)"><span class="SelectionMark">&#160;</span>Enumerations</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(6)"><span class="SelectionMark">&#160;</span>Enumerator</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(7)"><span class="SelectionMark">&#160;</span>Groups</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(8)"><span class="SelectionMark">&#160;</span>Pages</a></div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div class="header">
  <div class="summary">
<a href="#nested-classes">Data Structures</a> &#124;
<a href="#typedef-members">Typedefs</a> &#124;
<a href="#enum-members">Enumerations</a>  </div>
  <div class="headertitle">
<div class="title">I2C Driver<div class="ingroups"><a class="el" href="group__i2c.html">I2C: Inter-Integrated Circuit Driver</a></div></div>  </div>
</div><!--header-->
<div class="contents">
<a name="details" id="details"></a><h2 class="groupheader">Overview</h2>
<p>The MCUXpresso SDK provides a peripheral driver for the Inter-Integrated Circuit (I2C) module of MCUXpresso SDK devices.</p>
<p>The I2C driver includes functional APIs and transactional APIs.</p>
<p>Functional APIs target the low-level APIs. Functional APIs can be used for the I2C master/slave initialization/configuration/operation for optimization/customization purpose. Using the functional APIs requires knowing the I2C master peripheral and how to organize functional APIs to meet the application requirements. The I2C functional operation groups provide the functional APIs set.</p>
<p>Transactional APIs target the high-level APIs. The transactional APIs can be used to enable the peripheral quickly and also in the application if the code size and performance of transactional APIs satisfy the requirements. If the code size and performance are critical requirements, see the transactional API implementation and write custom code using the functional APIs or accessing the hardware registers.</p>
<p>Transactional APIs support asynchronous transfer. This means that the functions <a class="el" href="group__i2c__driver.html#gac7f76a04b6f6873c52ad176d58901fe9" title="Performs a master interrupt non-blocking transfer on the I2C bus. ">I2C_MasterTransferNonBlocking()</a> set up the interrupt non-blocking transfer. When the transfer completes, the upper layer is notified through a callback function with the status.</p>
<h1><a class="anchor" id="I2CTpyUC"></a>
Typical use case</h1>
<h2><a class="anchor" id="I2CMasterOpsFunctional"></a>
Master Operation in functional method</h2>
<div class="fragment"><div class="line"><a class="code" href="group__i2c__driver.html#structi2c__master__config__t">i2c_master_config_t</a> masterConfig;</div>
<div class="line">uint8_t status;</div>
<div class="line">status_t result = kStatus_Success;</div>
<div class="line">uint8_t txBuff[BUFFER_SIZE];</div>
<div class="line"></div>
<div class="line"><span class="comment">/* Gets the default configuration for master. */</span></div>
<div class="line"><a class="code" href="group__i2c__driver.html#gad69f2d63ea756dda60749ff6b09f587d">I2C_MasterGetDefaultConfig</a>(&amp;masterConfig);</div>
<div class="line"></div>
<div class="line"><span class="comment">/* Inititializes the I2C master. */</span></div>
<div class="line"><a class="code" href="group__i2c__driver.html#ga29f967b3ae8487a36ba2a58deb01ccae">I2C_MasterInit</a>(EXAMPLE_I2C_MASTER_BASEADDR, &amp;masterConfig, I2C_MASTER_CLK);</div>
<div class="line"></div>
<div class="line"><span class="comment">/* Sends a start and a slave address. */</span></div>
<div class="line"><a class="code" href="group__i2c__driver.html#ga7664234966e4162e952b6d57efcaa8a6">I2C_MasterStart</a>(EXAMPLE_I2C_MASTER_BASEADDR, 7-bit slave address, <a class="code" href="group__i2c__driver.html#ggab49c827b45635206f06e5737606e4611a93b476b469c2a4bfed5916b458ae9bb0">kI2C_Write</a>/<a class="code" href="group__i2c__driver.html#ggab49c827b45635206f06e5737606e4611a3a7bb24dc8d1c1be8925603eeafe9b30">kI2C_Read</a>);</div>
<div class="line"></div>
<div class="line"><span class="comment">/* Waits for the sent out address. */</span></div>
<div class="line"><span class="keywordflow">while</span>(!((status = <a class="code" href="group__i2c__driver.html#ga8219cf80c3be6c15fc5035326b7f62dc">I2C_MasterGetStatusFlags</a>(EXAMPLE_I2C_MASTER_BASEADDR)) &amp; <a class="code" href="group__i2c__driver.html#gga1f1337bbe9d0b184d9dcee31f9ebade2a647d0b1d1f9514ad483bef3ea3926c3b">kI2C_IntPendingFlag</a>))</div>
<div class="line">{</div>
<div class="line"></div>
<div class="line">}</div>
<div class="line"></div>
<div class="line"><span class="keywordflow">if</span>(status &amp; <a class="code" href="group__i2c__driver.html#gga1f1337bbe9d0b184d9dcee31f9ebade2a4c3c2928e17ddbfbc1c346c6b9a8dccd">kI2C_ReceiveNakFlag</a>)</div>
<div class="line">{</div>
<div class="line">    <span class="keywordflow">return</span> <a class="code" href="group__i2c__driver.html#gga7cc91c89125c25a88e463a9e8550b284a72fd33d0b5263a63766e62f71d16be00">kStatus_I2C_Nak</a>;</div>
<div class="line">}</div>
<div class="line"></div>
<div class="line">result = <a class="code" href="group__i2c__driver.html#gac4e1a954243aa852cb4d358e90091efd">I2C_MasterWriteBlocking</a>(EXAMPLE_I2C_MASTER_BASEADDR, txBuff, BUFFER_SIZE, <a class="code" href="group__i2c__driver.html#gga87ea07668194cfb46c7c368d2cb42433ae80f7b768b1621e42ac965d3d23de5e2">kI2C_TransferDefaultFlag</a>);</div>
<div class="line"></div>
<div class="line"><span class="keywordflow">return</span> result;</div>
</div><!-- fragment --><h2><a class="anchor" id="I2CMasterOpsTransIRQ"></a>
Master Operation in interrupt transactional method</h2>
<div class="fragment"><div class="line">i2c_master_handle_t g_m_handle;</div>
<div class="line"><span class="keyword">volatile</span> <span class="keywordtype">bool</span> g_MasterCompletionFlag = <span class="keyword">false</span>;</div>
<div class="line"><a class="code" href="group__i2c__driver.html#structi2c__master__config__t">i2c_master_config_t</a> masterConfig;</div>
<div class="line">uint8_t status;</div>
<div class="line">status_t result = kStatus_Success;</div>
<div class="line">uint8_t txBuff[BUFFER_SIZE];</div>
<div class="line"><a class="code" href="group__i2c__driver.html#structi2c__master__transfer__t">i2c_master_transfer_t</a> masterXfer;</div>
<div class="line"></div>
<div class="line"><span class="keyword">static</span> <span class="keywordtype">void</span> i2c_master_callback(I2C_Type *base, i2c_master_handle_t *handle, status_t status, <span class="keywordtype">void</span> *userData)</div>
<div class="line">{</div>
<div class="line">    <span class="comment">/* Signal transfer success when received success status. */</span></div>
<div class="line">    <span class="keywordflow">if</span> (status == kStatus_Success)</div>
<div class="line">    {</div>
<div class="line">        g_MasterCompletionFlag = <span class="keyword">true</span>;</div>
<div class="line">    }</div>
<div class="line">}</div>
<div class="line"></div>
<div class="line"><span class="comment">/* Gets a default configuration for master. */</span></div>
<div class="line"><a class="code" href="group__i2c__driver.html#gad69f2d63ea756dda60749ff6b09f587d">I2C_MasterGetDefaultConfig</a>(&amp;masterConfig);</div>
<div class="line"></div>
<div class="line"><span class="comment">/* Initializes the I2C master. */</span></div>
<div class="line"><a class="code" href="group__i2c__driver.html#ga29f967b3ae8487a36ba2a58deb01ccae">I2C_MasterInit</a>(EXAMPLE_I2C_MASTER_BASEADDR, &amp;masterConfig, I2C_MASTER_CLK);</div>
<div class="line"></div>
<div class="line">masterXfer.<a class="code" href="group__i2c__driver.html#a3b9c4ae818b1194955db51de0f67795f">slaveAddress</a> = I2C_MASTER_SLAVE_ADDR_7BIT;</div>
<div class="line">masterXfer.<a class="code" href="group__i2c__driver.html#ac5b89dc9115b7760431c981e0c1fd443">direction</a> = <a class="code" href="group__i2c__driver.html#ggab49c827b45635206f06e5737606e4611a93b476b469c2a4bfed5916b458ae9bb0">kI2C_Write</a>;</div>
<div class="line">masterXfer.<a class="code" href="group__i2c__driver.html#ae7facb612714785d4e143e57d47a5af3">subaddress</a> = NULL;</div>
<div class="line">masterXfer.<a class="code" href="group__i2c__driver.html#a9c08797f65f0faac78f44ac038c45c38">subaddressSize</a> = 0;</div>
<div class="line">masterXfer.<a class="code" href="group__i2c__driver.html#a0b4fa495c845d29fe6eaad7350337943">data</a> = txBuff;</div>
<div class="line">masterXfer.<a class="code" href="group__i2c__driver.html#a071d26432bea08e4bf76bb4eb8805770">dataSize</a> = BUFFER_SIZE;</div>
<div class="line">masterXfer.<a class="code" href="group__i2c__driver.html#a8835787e1b0f9a4b8868e7cbe53e45d5">flags</a> = <a class="code" href="group__i2c__driver.html#gga87ea07668194cfb46c7c368d2cb42433ae80f7b768b1621e42ac965d3d23de5e2">kI2C_TransferDefaultFlag</a>;</div>
<div class="line"></div>
<div class="line"><a class="code" href="group__i2c__driver.html#ga31e3de02b57801c6896e6045c4a31268">I2C_MasterTransferCreateHandle</a>(EXAMPLE_I2C_MASTER_BASEADDR, &amp;g_m_handle, i2c_master_callback, NULL);</div>
<div class="line"><a class="code" href="group__i2c__driver.html#gac7f76a04b6f6873c52ad176d58901fe9">I2C_MasterTransferNonBlocking</a>(EXAMPLE_I2C_MASTER_BASEADDR, &amp;g_m_handle, &amp;masterXfer);</div>
<div class="line"></div>
<div class="line"><span class="comment">/*  Waits for a transfer to be completed. */</span></div>
<div class="line"><span class="keywordflow">while</span> (!g_MasterCompletionFlag)</div>
<div class="line">{</div>
<div class="line">}</div>
<div class="line">g_MasterCompletionFlag = <span class="keyword">false</span>;</div>
</div><!-- fragment --><h2><a class="anchor" id="I2CSlaveOpsFunctional"></a>
Slave Operation in functional method</h2>
<div class="fragment"><div class="line"><a class="code" href="group__i2c__driver.html#structi2c__slave__config__t">i2c_slave_config_t</a> slaveConfig;</div>
<div class="line">uint8_t status;</div>
<div class="line">status_t result = kStatus_Success;</div>
<div class="line"></div>
<div class="line"><a class="code" href="group__i2c__driver.html#ga7115f80e28b62bbbd3be1a2a918529ba">I2C_SlaveGetDefaultConfig</a>(&amp;slaveConfig); <span class="comment">/*A default configuration 7-bit addressing mode*/</span></div>
<div class="line">slaveConfig.slaveAddr = 7-bit address;</div>
<div class="line"><a class="code" href="group__i2c__driver.html#gae6e155a5aadb43d527418e2965e39123">I2C_SlaveInit</a>(EXAMPLE_I2C_SLAVE_BASEADDR, &amp;slaveConfig);</div>
<div class="line"></div>
<div class="line"><span class="comment">/* Waits for an address match. */</span></div>
<div class="line"><span class="keywordflow">while</span>(!((status = <a class="code" href="group__i2c__driver.html#gac2794e138d94d9b6a761c074ad0899cd">I2C_SlaveGetStatusFlags</a>(EXAMPLE_I2C_SLAVE_BASEADDR)) &amp; <a class="code" href="group__i2c__driver.html#gga1f1337bbe9d0b184d9dcee31f9ebade2a10cd5797b1b8f809192423486a85d5fe">kI2C_AddressMatchFlag</a>))</div>
<div class="line">{</div>
<div class="line"></div>
<div class="line">}</div>
<div class="line"></div>
<div class="line"><span class="comment">/* A slave transmits; master is reading from the slave. */</span></div>
<div class="line"><span class="keywordflow">if</span> (status &amp; <a class="code" href="group__i2c__driver.html#gga1f1337bbe9d0b184d9dcee31f9ebade2a249f698970909f33b1b96139c05bd969">kI2C_TransferDirectionFlag</a>)</div>
<div class="line">{</div>
<div class="line">    result = <a class="code" href="group__i2c__driver.html#ga280404c6b1ede542f2c1c20bd382869c">I2C_SlaveWriteBlocking</a>(EXAMPLE_I2C_SLAVE_BASEADDR);</div>
<div class="line">}</div>
<div class="line"><span class="keywordflow">else</span></div>
<div class="line">{</div>
<div class="line">    <a class="code" href="group__i2c__driver.html#gaf7409e50ffd9b260744c13863c7a3987">I2C_SlaveReadBlocking</a>(EXAMPLE_I2C_SLAVE_BASEADDR);</div>
<div class="line">}</div>
<div class="line"></div>
<div class="line"><span class="keywordflow">return</span> result;</div>
</div><!-- fragment --><h2><a class="anchor" id="I2CSlaveOpsTransIRQ"></a>
Slave Operation in interrupt transactional method</h2>
<div class="fragment"><div class="line"><a class="code" href="group__i2c__driver.html#structi2c__slave__config__t">i2c_slave_config_t</a> slaveConfig;</div>
<div class="line">i2c_slave_handle_t g_s_handle;</div>
<div class="line"><span class="keyword">volatile</span> <span class="keywordtype">bool</span> g_SlaveCompletionFlag = <span class="keyword">false</span>;</div>
<div class="line"></div>
<div class="line"><span class="keyword">static</span> <span class="keywordtype">void</span> i2c_slave_callback(I2C_Type *base, <a class="code" href="group__i2c__driver.html#structi2c__slave__transfer__t">i2c_slave_transfer_t</a> *xfer, <span class="keywordtype">void</span> *userData)</div>
<div class="line">{</div>
<div class="line">    <span class="keywordflow">switch</span> (xfer-&gt;<a class="code" href="group__i2c__driver.html#ad0a9e837e9df16d89bab98a78af5bd10">event</a>)</div>
<div class="line">    {</div>
<div class="line">        <span class="comment">/*  Transmit request */</span></div>
<div class="line">        <span class="keywordflow">case</span> <a class="code" href="group__i2c__driver.html#ggac53e5c96a2eed1b5a95b7d84be48f4aca2f85039a57379838909876a1d509b7aa">kI2C_SlaveTransmitEvent</a>:</div>
<div class="line">            <span class="comment">/*  Update information for transmit process */</span></div>
<div class="line">            xfer-&gt;<a class="code" href="group__i2c__driver.html#ae8dab4de2445f3094b6baef3712a80a9">data</a> = g_slave_buff;</div>
<div class="line">            xfer-&gt;<a class="code" href="group__i2c__driver.html#a96d433bce400dfc4917343f2b07e8b1d">dataSize</a> = I2C_DATA_LENGTH;</div>
<div class="line">            <span class="keywordflow">break</span>;</div>
<div class="line"></div>
<div class="line">        <span class="comment">/*  Receives request */</span></div>
<div class="line">        <span class="keywordflow">case</span> <a class="code" href="group__i2c__driver.html#ggac53e5c96a2eed1b5a95b7d84be48f4acaac8593e808a8137d1b5d3a51640779de">kI2C_SlaveReceiveEvent</a>:</div>
<div class="line">            <span class="comment">/*  Update information for received process */</span></div>
<div class="line">            xfer-&gt;<a class="code" href="group__i2c__driver.html#ae8dab4de2445f3094b6baef3712a80a9">data</a> = g_slave_buff;</div>
<div class="line">            xfer-&gt;<a class="code" href="group__i2c__driver.html#a96d433bce400dfc4917343f2b07e8b1d">dataSize</a> = I2C_DATA_LENGTH;</div>
<div class="line">            <span class="keywordflow">break</span>;</div>
<div class="line"></div>
<div class="line">        <span class="comment">/*  Transfer is done */</span></div>
<div class="line">        <span class="keywordflow">case</span> <a class="code" href="group__i2c__driver.html#ggac53e5c96a2eed1b5a95b7d84be48f4aca38cca3cd668e73f51b8e574835d419df">kI2C_SlaveCompletionEvent</a>:</div>
<div class="line">            g_SlaveCompletionFlag = <span class="keyword">true</span>;</div>
<div class="line">            <span class="keywordflow">break</span>;</div>
<div class="line"></div>
<div class="line">        <span class="keywordflow">default</span>:</div>
<div class="line">            g_SlaveCompletionFlag = <span class="keyword">true</span>;</div>
<div class="line">            <span class="keywordflow">break</span>;</div>
<div class="line">    }</div>
<div class="line">}</div>
<div class="line"></div>
<div class="line"><a class="code" href="group__i2c__driver.html#ga7115f80e28b62bbbd3be1a2a918529ba">I2C_SlaveGetDefaultConfig</a>(&amp;slaveConfig); <span class="comment">/*A default configuration 7-bit addressing mode*/</span></div>
<div class="line">slaveConfig.slaveAddr = 7-bit address;</div>
<div class="line"></div>
<div class="line"><a class="code" href="group__i2c__driver.html#gae6e155a5aadb43d527418e2965e39123">I2C_SlaveInit</a>(EXAMPLE_I2C_SLAVE_BASEADDR, &amp;slaveConfig);</div>
<div class="line"></div>
<div class="line"><a class="code" href="group__i2c__driver.html#gac9b90f575d92ff8ad3cc350a5c8ad1b9">I2C_SlaveTransferCreateHandle</a>(EXAMPLE_I2C_SLAVE_BASEADDR, &amp;g_s_handle, i2c_slave_callback, NULL);</div>
<div class="line"></div>
<div class="line"><a class="code" href="group__i2c__driver.html#gaa387d81ea08a9d4b39cfeb3dfec505f7">I2C_SlaveTransferNonBlocking</a>(EXAMPLE_I2C_SLAVE_BASEADDR, &amp;g_s_handle, <a class="code" href="group__i2c__driver.html#ggac53e5c96a2eed1b5a95b7d84be48f4aca38cca3cd668e73f51b8e574835d419df">kI2C_SlaveCompletionEvent</a>);</div>
<div class="line"></div>
<div class="line"><span class="comment">/*  Waits for a transfer to be completed. */</span></div>
<div class="line"><span class="keywordflow">while</span> (!g_SlaveCompletionFlag)</div>
<div class="line">{</div>
<div class="line">}</div>
<div class="line">g_SlaveCompletionFlag = <span class="keyword">false</span>;</div>
</div><!-- fragment --> <table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="nested-classes"></a>
Data Structures</h2></td></tr>
<tr class="memitem:structi2c__master__config__t"><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#structi2c__master__config__t">i2c_master_config_t</a></td></tr>
<tr class="memdesc:structi2c__master__config__t"><td class="mdescLeft">&#160;</td><td class="mdescRight">I2C master user configuration.  <a href="group__i2c__driver.html#structi2c__master__config__t">More...</a><br/></td></tr>
<tr class="separator:structi2c__master__config__t"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:structi2c__master__transfer__t"><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#structi2c__master__transfer__t">i2c_master_transfer_t</a></td></tr>
<tr class="memdesc:structi2c__master__transfer__t"><td class="mdescLeft">&#160;</td><td class="mdescRight">I2C master transfer structure.  <a href="group__i2c__driver.html#structi2c__master__transfer__t">More...</a><br/></td></tr>
<tr class="separator:structi2c__master__transfer__t"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:struct__i2c__master__handle"><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#struct__i2c__master__handle">i2c_master_handle_t</a></td></tr>
<tr class="memdesc:struct__i2c__master__handle"><td class="mdescLeft">&#160;</td><td class="mdescRight">I2C master handle structure.  <a href="group__i2c__driver.html#struct__i2c__master__handle">More...</a><br/></td></tr>
<tr class="separator:struct__i2c__master__handle"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:structi2c__slave__config__t"><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#structi2c__slave__config__t">i2c_slave_config_t</a></td></tr>
<tr class="memdesc:structi2c__slave__config__t"><td class="mdescLeft">&#160;</td><td class="mdescRight">I2C slave user configuration.  <a href="group__i2c__driver.html#structi2c__slave__config__t">More...</a><br/></td></tr>
<tr class="separator:structi2c__slave__config__t"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:structi2c__slave__transfer__t"><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#structi2c__slave__transfer__t">i2c_slave_transfer_t</a></td></tr>
<tr class="memdesc:structi2c__slave__transfer__t"><td class="mdescLeft">&#160;</td><td class="mdescRight">I2C slave transfer structure.  <a href="group__i2c__driver.html#structi2c__slave__transfer__t">More...</a><br/></td></tr>
<tr class="separator:structi2c__slave__transfer__t"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:struct__i2c__slave__handle"><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#struct__i2c__slave__handle">i2c_slave_handle_t</a></td></tr>
<tr class="memdesc:struct__i2c__slave__handle"><td class="mdescLeft">&#160;</td><td class="mdescRight">I2C slave handle structure.  <a href="group__i2c__driver.html#struct__i2c__slave__handle">More...</a><br/></td></tr>
<tr class="separator:struct__i2c__slave__handle"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="typedef-members"></a>
Typedefs</h2></td></tr>
<tr class="memitem:ga1c6e059706357c744c165ce7ecd1c185"><td class="memItemLeft" align="right" valign="top">typedef void(*&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#ga1c6e059706357c744c165ce7ecd1c185">i2c_master_transfer_callback_t</a> )(I2C_Type *base, i2c_master_handle_t *handle, status_t status, void *userData)</td></tr>
<tr class="memdesc:ga1c6e059706357c744c165ce7ecd1c185"><td class="mdescLeft">&#160;</td><td class="mdescRight">I2C master transfer callback typedef.  <a href="#ga1c6e059706357c744c165ce7ecd1c185">More...</a><br/></td></tr>
<tr class="separator:ga1c6e059706357c744c165ce7ecd1c185"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga974310ded85af5ef341811d542db650c"><td class="memItemLeft" align="right" valign="top">typedef void(*&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#ga974310ded85af5ef341811d542db650c">i2c_slave_transfer_callback_t</a> )(I2C_Type *base, <a class="el" href="group__i2c__driver.html#structi2c__slave__transfer__t">i2c_slave_transfer_t</a> *xfer, void *userData)</td></tr>
<tr class="memdesc:ga974310ded85af5ef341811d542db650c"><td class="mdescLeft">&#160;</td><td class="mdescRight">I2C slave transfer callback typedef.  <a href="#ga974310ded85af5ef341811d542db650c">More...</a><br/></td></tr>
<tr class="separator:ga974310ded85af5ef341811d542db650c"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="enum-members"></a>
Enumerations</h2></td></tr>
<tr class="memitem:ga7cc91c89125c25a88e463a9e8550b284"><td class="memItemLeft" align="right" valign="top">enum &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#ga7cc91c89125c25a88e463a9e8550b284">_i2c_status</a> { <br/>
&#160;&#160;<a class="el" href="group__i2c__driver.html#gga7cc91c89125c25a88e463a9e8550b284a49091894b590d7e479605bf113918952">kStatus_I2C_Busy</a> = MAKE_STATUS(kStatusGroup_I2C, 0), 
<br/>
&#160;&#160;<a class="el" href="group__i2c__driver.html#gga7cc91c89125c25a88e463a9e8550b284a628d242f7bc0e3d5949c7f73eafaa508">kStatus_I2C_Idle</a> = MAKE_STATUS(kStatusGroup_I2C, 1), 
<br/>
&#160;&#160;<a class="el" href="group__i2c__driver.html#gga7cc91c89125c25a88e463a9e8550b284a72fd33d0b5263a63766e62f71d16be00">kStatus_I2C_Nak</a> = MAKE_STATUS(kStatusGroup_I2C, 2), 
<br/>
&#160;&#160;<a class="el" href="group__i2c__driver.html#gga7cc91c89125c25a88e463a9e8550b284a139b52cc3305ec2c06d0ac94313c221f">kStatus_I2C_ArbitrationLost</a> = MAKE_STATUS(kStatusGroup_I2C, 3), 
<br/>
&#160;&#160;<a class="el" href="group__i2c__driver.html#gga7cc91c89125c25a88e463a9e8550b284a81ad7cc198436cabbe91ea55c5288747">kStatus_I2C_Timeout</a> = MAKE_STATUS(kStatusGroup_I2C, 4), 
<br/>
&#160;&#160;<a class="el" href="group__i2c__driver.html#gga7cc91c89125c25a88e463a9e8550b284adf7437bfedcc0d57338ed33f1be5c805">kStatus_I2C_Addr_Nak</a> = MAKE_STATUS(kStatusGroup_I2C, 5)
<br/>
 }</td></tr>
<tr class="memdesc:ga7cc91c89125c25a88e463a9e8550b284"><td class="mdescLeft">&#160;</td><td class="mdescRight">I2C status return codes.  <a href="group__i2c__driver.html#ga7cc91c89125c25a88e463a9e8550b284">More...</a><br/></td></tr>
<tr class="separator:ga7cc91c89125c25a88e463a9e8550b284"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga1f1337bbe9d0b184d9dcee31f9ebade2"><td class="memItemLeft" align="right" valign="top">enum &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#ga1f1337bbe9d0b184d9dcee31f9ebade2">_i2c_flags</a> { <br/>
&#160;&#160;<a class="el" href="group__i2c__driver.html#gga1f1337bbe9d0b184d9dcee31f9ebade2a4c3c2928e17ddbfbc1c346c6b9a8dccd">kI2C_ReceiveNakFlag</a> = I2C_I2SR_RXAK_MASK, 
<br/>
&#160;&#160;<a class="el" href="group__i2c__driver.html#gga1f1337bbe9d0b184d9dcee31f9ebade2a647d0b1d1f9514ad483bef3ea3926c3b">kI2C_IntPendingFlag</a> = I2C_I2SR_IIF_MASK, 
<br/>
&#160;&#160;<a class="el" href="group__i2c__driver.html#gga1f1337bbe9d0b184d9dcee31f9ebade2a249f698970909f33b1b96139c05bd969">kI2C_TransferDirectionFlag</a> = I2C_I2SR_SRW_MASK, 
<br/>
&#160;&#160;<a class="el" href="group__i2c__driver.html#gga1f1337bbe9d0b184d9dcee31f9ebade2a39fab5ef04e74d00ef4c4574899ab589">kI2C_ArbitrationLostFlag</a> = I2C_I2SR_IAL_MASK, 
<br/>
&#160;&#160;<a class="el" href="group__i2c__driver.html#gga1f1337bbe9d0b184d9dcee31f9ebade2a37fb20742a15a63c1bc2551b997cdcff">kI2C_BusBusyFlag</a> = I2C_I2SR_IBB_MASK, 
<br/>
&#160;&#160;<a class="el" href="group__i2c__driver.html#gga1f1337bbe9d0b184d9dcee31f9ebade2a10cd5797b1b8f809192423486a85d5fe">kI2C_AddressMatchFlag</a> = I2C_I2SR_IAAS_MASK, 
<br/>
&#160;&#160;<a class="el" href="group__i2c__driver.html#gga1f1337bbe9d0b184d9dcee31f9ebade2adb8f10365dfc2a3e849f05173fa4d83e">kI2C_TransferCompleteFlag</a> = I2C_I2SR_ICF_MASK
<br/>
 }</td></tr>
<tr class="memdesc:ga1f1337bbe9d0b184d9dcee31f9ebade2"><td class="mdescLeft">&#160;</td><td class="mdescRight">I2C peripheral flags.  <a href="group__i2c__driver.html#ga1f1337bbe9d0b184d9dcee31f9ebade2">More...</a><br/></td></tr>
<tr class="separator:ga1f1337bbe9d0b184d9dcee31f9ebade2"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga87c81dd985dad07dc26cb93125a94ec7"><td class="memItemLeft" align="right" valign="top">enum &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#ga87c81dd985dad07dc26cb93125a94ec7">_i2c_interrupt_enable</a> { <a class="el" href="group__i2c__driver.html#gga87c81dd985dad07dc26cb93125a94ec7a5526e27ef6e8317ba928849da890b3b2">kI2C_GlobalInterruptEnable</a> = I2C_I2CR_IIEN_MASK
 }</td></tr>
<tr class="memdesc:ga87c81dd985dad07dc26cb93125a94ec7"><td class="mdescLeft">&#160;</td><td class="mdescRight">I2C feature interrupt source.  <a href="group__i2c__driver.html#ga87c81dd985dad07dc26cb93125a94ec7">More...</a><br/></td></tr>
<tr class="separator:ga87c81dd985dad07dc26cb93125a94ec7"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gab49c827b45635206f06e5737606e4611"><td class="memItemLeft" align="right" valign="top">enum &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#gab49c827b45635206f06e5737606e4611">i2c_direction_t</a> { <br/>
&#160;&#160;<a class="el" href="group__i2c__driver.html#ggab49c827b45635206f06e5737606e4611a93b476b469c2a4bfed5916b458ae9bb0">kI2C_Write</a> = 0x0U, 
<br/>
&#160;&#160;<a class="el" href="group__i2c__driver.html#ggab49c827b45635206f06e5737606e4611a3a7bb24dc8d1c1be8925603eeafe9b30">kI2C_Read</a> = 0x1U
<br/>
 }</td></tr>
<tr class="memdesc:gab49c827b45635206f06e5737606e4611"><td class="mdescLeft">&#160;</td><td class="mdescRight">The direction of master and slave transfers.  <a href="group__i2c__driver.html#gab49c827b45635206f06e5737606e4611">More...</a><br/></td></tr>
<tr class="separator:gab49c827b45635206f06e5737606e4611"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga87ea07668194cfb46c7c368d2cb42433"><td class="memItemLeft" align="right" valign="top">enum &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#ga87ea07668194cfb46c7c368d2cb42433">_i2c_master_transfer_flags</a> { <br/>
&#160;&#160;<a class="el" href="group__i2c__driver.html#gga87ea07668194cfb46c7c368d2cb42433ae80f7b768b1621e42ac965d3d23de5e2">kI2C_TransferDefaultFlag</a> = 0x0U, 
<br/>
&#160;&#160;<a class="el" href="group__i2c__driver.html#gga87ea07668194cfb46c7c368d2cb42433a5cb44bf860c0482c0ca0165cf0d31d8a">kI2C_TransferNoStartFlag</a> = 0x1U, 
<br/>
&#160;&#160;<a class="el" href="group__i2c__driver.html#gga87ea07668194cfb46c7c368d2cb42433aadf112471ef12f194985a093cd9b9721">kI2C_TransferRepeatedStartFlag</a> = 0x2U, 
<br/>
&#160;&#160;<a class="el" href="group__i2c__driver.html#gga87ea07668194cfb46c7c368d2cb42433afb8aeea71b5b7475e3d3df86220db566">kI2C_TransferNoStopFlag</a> = 0x4U
<br/>
 }</td></tr>
<tr class="memdesc:ga87ea07668194cfb46c7c368d2cb42433"><td class="mdescLeft">&#160;</td><td class="mdescRight">I2C transfer control flag.  <a href="group__i2c__driver.html#ga87ea07668194cfb46c7c368d2cb42433">More...</a><br/></td></tr>
<tr class="separator:ga87ea07668194cfb46c7c368d2cb42433"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gac53e5c96a2eed1b5a95b7d84be48f4ac"><td class="memItemLeft" align="right" valign="top">enum &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#gac53e5c96a2eed1b5a95b7d84be48f4ac">i2c_slave_transfer_event_t</a> { <br/>
&#160;&#160;<a class="el" href="group__i2c__driver.html#ggac53e5c96a2eed1b5a95b7d84be48f4acacb1ae174dd6798a6fd79800a9e39a3c6">kI2C_SlaveAddressMatchEvent</a> = 0x01U, 
<br/>
&#160;&#160;<a class="el" href="group__i2c__driver.html#ggac53e5c96a2eed1b5a95b7d84be48f4aca2f85039a57379838909876a1d509b7aa">kI2C_SlaveTransmitEvent</a> = 0x02U, 
<br/>
&#160;&#160;<a class="el" href="group__i2c__driver.html#ggac53e5c96a2eed1b5a95b7d84be48f4acaac8593e808a8137d1b5d3a51640779de">kI2C_SlaveReceiveEvent</a> = 0x04U, 
<br/>
&#160;&#160;<a class="el" href="group__i2c__driver.html#ggac53e5c96a2eed1b5a95b7d84be48f4aca43c045da27fa60e7a0540c743eca4e79">kI2C_SlaveTransmitAckEvent</a> = 0x08U, 
<br/>
&#160;&#160;<a class="el" href="group__i2c__driver.html#ggac53e5c96a2eed1b5a95b7d84be48f4aca38cca3cd668e73f51b8e574835d419df">kI2C_SlaveCompletionEvent</a> = 0x20U, 
<br/>
&#160;&#160;<a class="el" href="group__i2c__driver.html#ggac53e5c96a2eed1b5a95b7d84be48f4aca94b030ebdac378a84961893ae567bfbc">kI2C_SlaveAllEvents</a>
<br/>
 }</td></tr>
<tr class="memdesc:gac53e5c96a2eed1b5a95b7d84be48f4ac"><td class="mdescLeft">&#160;</td><td class="mdescRight">Set of events sent to the callback for nonblocking slave transfers.  <a href="group__i2c__driver.html#gac53e5c96a2eed1b5a95b7d84be48f4ac">More...</a><br/></td></tr>
<tr class="separator:gac53e5c96a2eed1b5a95b7d84be48f4ac"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="member-group"></a>
Driver version</h2></td></tr>
<tr class="memitem:ga60fdaec284298758a650ce1122aef231"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#ga60fdaec284298758a650ce1122aef231">FSL_I2C_DRIVER_VERSION</a>&#160;&#160;&#160;(MAKE_VERSION(2, 0, 0))</td></tr>
<tr class="memdesc:ga60fdaec284298758a650ce1122aef231"><td class="mdescLeft">&#160;</td><td class="mdescRight">I2C driver version 2.0.0.  <a href="#ga60fdaec284298758a650ce1122aef231">More...</a><br/></td></tr>
<tr class="separator:ga60fdaec284298758a650ce1122aef231"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="member-group"></a>
Initialization and deinitialization</h2></td></tr>
<tr class="memitem:ga29f967b3ae8487a36ba2a58deb01ccae"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#ga29f967b3ae8487a36ba2a58deb01ccae">I2C_MasterInit</a> (I2C_Type *base, const <a class="el" href="group__i2c__driver.html#structi2c__master__config__t">i2c_master_config_t</a> *masterConfig, uint32_t srcClock_Hz)</td></tr>
<tr class="memdesc:ga29f967b3ae8487a36ba2a58deb01ccae"><td class="mdescLeft">&#160;</td><td class="mdescRight">Initializes the I2C peripheral.  <a href="#ga29f967b3ae8487a36ba2a58deb01ccae">More...</a><br/></td></tr>
<tr class="separator:ga29f967b3ae8487a36ba2a58deb01ccae"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gadcf7122f0a38d4d9da0f052fcb167957"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#gadcf7122f0a38d4d9da0f052fcb167957">I2C_MasterDeinit</a> (I2C_Type *base)</td></tr>
<tr class="memdesc:gadcf7122f0a38d4d9da0f052fcb167957"><td class="mdescLeft">&#160;</td><td class="mdescRight">De-initializes the I2C master peripheral.  <a href="#gadcf7122f0a38d4d9da0f052fcb167957">More...</a><br/></td></tr>
<tr class="separator:gadcf7122f0a38d4d9da0f052fcb167957"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gad69f2d63ea756dda60749ff6b09f587d"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#gad69f2d63ea756dda60749ff6b09f587d">I2C_MasterGetDefaultConfig</a> (<a class="el" href="group__i2c__driver.html#structi2c__master__config__t">i2c_master_config_t</a> *masterConfig)</td></tr>
<tr class="memdesc:gad69f2d63ea756dda60749ff6b09f587d"><td class="mdescLeft">&#160;</td><td class="mdescRight">Sets the I2C master configuration structure to default values.  <a href="#gad69f2d63ea756dda60749ff6b09f587d">More...</a><br/></td></tr>
<tr class="separator:gad69f2d63ea756dda60749ff6b09f587d"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gae6e155a5aadb43d527418e2965e39123"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#gae6e155a5aadb43d527418e2965e39123">I2C_SlaveInit</a> (I2C_Type *base, const <a class="el" href="group__i2c__driver.html#structi2c__slave__config__t">i2c_slave_config_t</a> *slaveConfig)</td></tr>
<tr class="memdesc:gae6e155a5aadb43d527418e2965e39123"><td class="mdescLeft">&#160;</td><td class="mdescRight">Initializes the I2C peripheral.  <a href="#gae6e155a5aadb43d527418e2965e39123">More...</a><br/></td></tr>
<tr class="separator:gae6e155a5aadb43d527418e2965e39123"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gadb50014db29dd75ea2001fb7bc837e77"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#gadb50014db29dd75ea2001fb7bc837e77">I2C_SlaveDeinit</a> (I2C_Type *base)</td></tr>
<tr class="memdesc:gadb50014db29dd75ea2001fb7bc837e77"><td class="mdescLeft">&#160;</td><td class="mdescRight">De-initializes the I2C slave peripheral.  <a href="#gadb50014db29dd75ea2001fb7bc837e77">More...</a><br/></td></tr>
<tr class="separator:gadb50014db29dd75ea2001fb7bc837e77"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga7115f80e28b62bbbd3be1a2a918529ba"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#ga7115f80e28b62bbbd3be1a2a918529ba">I2C_SlaveGetDefaultConfig</a> (<a class="el" href="group__i2c__driver.html#structi2c__slave__config__t">i2c_slave_config_t</a> *slaveConfig)</td></tr>
<tr class="memdesc:ga7115f80e28b62bbbd3be1a2a918529ba"><td class="mdescLeft">&#160;</td><td class="mdescRight">Sets the I2C slave configuration structure to default values.  <a href="#ga7115f80e28b62bbbd3be1a2a918529ba">More...</a><br/></td></tr>
<tr class="separator:ga7115f80e28b62bbbd3be1a2a918529ba"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gaaaaab1e83cb8c6117046bdb5bcbf9ac6"><td class="memItemLeft" align="right" valign="top">static void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#gaaaaab1e83cb8c6117046bdb5bcbf9ac6">I2C_Enable</a> (I2C_Type *base, bool enable)</td></tr>
<tr class="memdesc:gaaaaab1e83cb8c6117046bdb5bcbf9ac6"><td class="mdescLeft">&#160;</td><td class="mdescRight">Enables or disabless the I2C peripheral operation.  <a href="#gaaaaab1e83cb8c6117046bdb5bcbf9ac6">More...</a><br/></td></tr>
<tr class="separator:gaaaaab1e83cb8c6117046bdb5bcbf9ac6"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="member-group"></a>
Status</h2></td></tr>
<tr class="memitem:ga8219cf80c3be6c15fc5035326b7f62dc"><td class="memItemLeft" align="right" valign="top">static uint32_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#ga8219cf80c3be6c15fc5035326b7f62dc">I2C_MasterGetStatusFlags</a> (I2C_Type *base)</td></tr>
<tr class="memdesc:ga8219cf80c3be6c15fc5035326b7f62dc"><td class="mdescLeft">&#160;</td><td class="mdescRight">Gets the I2C status flags.  <a href="#ga8219cf80c3be6c15fc5035326b7f62dc">More...</a><br/></td></tr>
<tr class="separator:ga8219cf80c3be6c15fc5035326b7f62dc"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga437271ffb955b77df0a5dee9ea80cc63"><td class="memItemLeft" align="right" valign="top">static void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#ga437271ffb955b77df0a5dee9ea80cc63">I2C_MasterClearStatusFlags</a> (I2C_Type *base, uint32_t statusMask)</td></tr>
<tr class="memdesc:ga437271ffb955b77df0a5dee9ea80cc63"><td class="mdescLeft">&#160;</td><td class="mdescRight">Clears the I2C status flag state.  <a href="#ga437271ffb955b77df0a5dee9ea80cc63">More...</a><br/></td></tr>
<tr class="separator:ga437271ffb955b77df0a5dee9ea80cc63"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gac2794e138d94d9b6a761c074ad0899cd"><td class="memItemLeft" align="right" valign="top">static uint32_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#gac2794e138d94d9b6a761c074ad0899cd">I2C_SlaveGetStatusFlags</a> (I2C_Type *base)</td></tr>
<tr class="memdesc:gac2794e138d94d9b6a761c074ad0899cd"><td class="mdescLeft">&#160;</td><td class="mdescRight">Gets the I2C status flags.  <a href="#gac2794e138d94d9b6a761c074ad0899cd">More...</a><br/></td></tr>
<tr class="separator:gac2794e138d94d9b6a761c074ad0899cd"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga545c1a43d8d49c4675de493d45a4063a"><td class="memItemLeft" align="right" valign="top">static void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#ga545c1a43d8d49c4675de493d45a4063a">I2C_SlaveClearStatusFlags</a> (I2C_Type *base, uint32_t statusMask)</td></tr>
<tr class="memdesc:ga545c1a43d8d49c4675de493d45a4063a"><td class="mdescLeft">&#160;</td><td class="mdescRight">Clears the I2C status flag state.  <a href="#ga545c1a43d8d49c4675de493d45a4063a">More...</a><br/></td></tr>
<tr class="separator:ga545c1a43d8d49c4675de493d45a4063a"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="member-group"></a>
Interrupts</h2></td></tr>
<tr class="memitem:ga577e094cc4d39b88ec5bbe49bc199c77"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#ga577e094cc4d39b88ec5bbe49bc199c77">I2C_EnableInterrupts</a> (I2C_Type *base, uint32_t mask)</td></tr>
<tr class="memdesc:ga577e094cc4d39b88ec5bbe49bc199c77"><td class="mdescLeft">&#160;</td><td class="mdescRight">Enables I2C interrupt requests.  <a href="#ga577e094cc4d39b88ec5bbe49bc199c77">More...</a><br/></td></tr>
<tr class="separator:ga577e094cc4d39b88ec5bbe49bc199c77"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga9839c1fd49a0f62f42b0adfa74f62853"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#ga9839c1fd49a0f62f42b0adfa74f62853">I2C_DisableInterrupts</a> (I2C_Type *base, uint32_t mask)</td></tr>
<tr class="memdesc:ga9839c1fd49a0f62f42b0adfa74f62853"><td class="mdescLeft">&#160;</td><td class="mdescRight">Disables I2C interrupt requests.  <a href="#ga9839c1fd49a0f62f42b0adfa74f62853">More...</a><br/></td></tr>
<tr class="separator:ga9839c1fd49a0f62f42b0adfa74f62853"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="member-group"></a>
Bus Operations</h2></td></tr>
<tr class="memitem:gafeab1d5249a8b39c8d9e1a54a85c23f0"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#gafeab1d5249a8b39c8d9e1a54a85c23f0">I2C_MasterSetBaudRate</a> (I2C_Type *base, uint32_t baudRate_Bps, uint32_t srcClock_Hz)</td></tr>
<tr class="memdesc:gafeab1d5249a8b39c8d9e1a54a85c23f0"><td class="mdescLeft">&#160;</td><td class="mdescRight">Sets the I2C master transfer baud rate.  <a href="#gafeab1d5249a8b39c8d9e1a54a85c23f0">More...</a><br/></td></tr>
<tr class="separator:gafeab1d5249a8b39c8d9e1a54a85c23f0"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga7664234966e4162e952b6d57efcaa8a6"><td class="memItemLeft" align="right" valign="top">status_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#ga7664234966e4162e952b6d57efcaa8a6">I2C_MasterStart</a> (I2C_Type *base, uint8_t address, <a class="el" href="group__i2c__driver.html#gab49c827b45635206f06e5737606e4611">i2c_direction_t</a> direction)</td></tr>
<tr class="memdesc:ga7664234966e4162e952b6d57efcaa8a6"><td class="mdescLeft">&#160;</td><td class="mdescRight">Sends a START on the I2C bus.  <a href="#ga7664234966e4162e952b6d57efcaa8a6">More...</a><br/></td></tr>
<tr class="separator:ga7664234966e4162e952b6d57efcaa8a6"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gaf46a8cc094fc18c6cadea8de71448723"><td class="memItemLeft" align="right" valign="top">status_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#gaf46a8cc094fc18c6cadea8de71448723">I2C_MasterStop</a> (I2C_Type *base)</td></tr>
<tr class="memdesc:gaf46a8cc094fc18c6cadea8de71448723"><td class="mdescLeft">&#160;</td><td class="mdescRight">Sends a STOP signal on the I2C bus.  <a href="#gaf46a8cc094fc18c6cadea8de71448723">More...</a><br/></td></tr>
<tr class="separator:gaf46a8cc094fc18c6cadea8de71448723"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga42ff265d25e713326c7d152adf350147"><td class="memItemLeft" align="right" valign="top">status_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#ga42ff265d25e713326c7d152adf350147">I2C_MasterRepeatedStart</a> (I2C_Type *base, uint8_t address, <a class="el" href="group__i2c__driver.html#gab49c827b45635206f06e5737606e4611">i2c_direction_t</a> direction)</td></tr>
<tr class="memdesc:ga42ff265d25e713326c7d152adf350147"><td class="mdescLeft">&#160;</td><td class="mdescRight">Sends a REPEATED START on the I2C bus.  <a href="#ga42ff265d25e713326c7d152adf350147">More...</a><br/></td></tr>
<tr class="separator:ga42ff265d25e713326c7d152adf350147"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gac4e1a954243aa852cb4d358e90091efd"><td class="memItemLeft" align="right" valign="top">status_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#gac4e1a954243aa852cb4d358e90091efd">I2C_MasterWriteBlocking</a> (I2C_Type *base, const uint8_t *txBuff, size_t txSize, uint32_t flags)</td></tr>
<tr class="memdesc:gac4e1a954243aa852cb4d358e90091efd"><td class="mdescLeft">&#160;</td><td class="mdescRight">Performs a polling send transaction on the I2C bus.  <a href="#gac4e1a954243aa852cb4d358e90091efd">More...</a><br/></td></tr>
<tr class="separator:gac4e1a954243aa852cb4d358e90091efd"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gaf77526f32a16109abf265dbb022a26ba"><td class="memItemLeft" align="right" valign="top">status_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#gaf77526f32a16109abf265dbb022a26ba">I2C_MasterReadBlocking</a> (I2C_Type *base, uint8_t *rxBuff, size_t rxSize, uint32_t flags)</td></tr>
<tr class="memdesc:gaf77526f32a16109abf265dbb022a26ba"><td class="mdescLeft">&#160;</td><td class="mdescRight">Performs a polling receive transaction on the I2C bus.  <a href="#gaf77526f32a16109abf265dbb022a26ba">More...</a><br/></td></tr>
<tr class="separator:gaf77526f32a16109abf265dbb022a26ba"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga280404c6b1ede542f2c1c20bd382869c"><td class="memItemLeft" align="right" valign="top">status_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#ga280404c6b1ede542f2c1c20bd382869c">I2C_SlaveWriteBlocking</a> (I2C_Type *base, const uint8_t *txBuff, size_t txSize)</td></tr>
<tr class="memdesc:ga280404c6b1ede542f2c1c20bd382869c"><td class="mdescLeft">&#160;</td><td class="mdescRight">Performs a polling send transaction on the I2C bus.  <a href="#ga280404c6b1ede542f2c1c20bd382869c">More...</a><br/></td></tr>
<tr class="separator:ga280404c6b1ede542f2c1c20bd382869c"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gaf7409e50ffd9b260744c13863c7a3987"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#gaf7409e50ffd9b260744c13863c7a3987">I2C_SlaveReadBlocking</a> (I2C_Type *base, uint8_t *rxBuff, size_t rxSize)</td></tr>
<tr class="memdesc:gaf7409e50ffd9b260744c13863c7a3987"><td class="mdescLeft">&#160;</td><td class="mdescRight">Performs a polling receive transaction on the I2C bus.  <a href="#gaf7409e50ffd9b260744c13863c7a3987">More...</a><br/></td></tr>
<tr class="separator:gaf7409e50ffd9b260744c13863c7a3987"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga35cae3a5b4aa50ce8db28e3eb703a027"><td class="memItemLeft" align="right" valign="top">status_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#ga35cae3a5b4aa50ce8db28e3eb703a027">I2C_MasterTransferBlocking</a> (I2C_Type *base, <a class="el" href="group__i2c__driver.html#structi2c__master__transfer__t">i2c_master_transfer_t</a> *xfer)</td></tr>
<tr class="memdesc:ga35cae3a5b4aa50ce8db28e3eb703a027"><td class="mdescLeft">&#160;</td><td class="mdescRight">Performs a master polling transfer on the I2C bus.  <a href="#ga35cae3a5b4aa50ce8db28e3eb703a027">More...</a><br/></td></tr>
<tr class="separator:ga35cae3a5b4aa50ce8db28e3eb703a027"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="member-group"></a>
Transactional</h2></td></tr>
<tr class="memitem:ga31e3de02b57801c6896e6045c4a31268"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#ga31e3de02b57801c6896e6045c4a31268">I2C_MasterTransferCreateHandle</a> (I2C_Type *base, i2c_master_handle_t *handle, <a class="el" href="group__i2c__driver.html#ga1c6e059706357c744c165ce7ecd1c185">i2c_master_transfer_callback_t</a> callback, void *userData)</td></tr>
<tr class="memdesc:ga31e3de02b57801c6896e6045c4a31268"><td class="mdescLeft">&#160;</td><td class="mdescRight">Initializes the I2C handle which is used in transactional functions.  <a href="#ga31e3de02b57801c6896e6045c4a31268">More...</a><br/></td></tr>
<tr class="separator:ga31e3de02b57801c6896e6045c4a31268"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gac7f76a04b6f6873c52ad176d58901fe9"><td class="memItemLeft" align="right" valign="top">status_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#gac7f76a04b6f6873c52ad176d58901fe9">I2C_MasterTransferNonBlocking</a> (I2C_Type *base, i2c_master_handle_t *handle, <a class="el" href="group__i2c__driver.html#structi2c__master__transfer__t">i2c_master_transfer_t</a> *xfer)</td></tr>
<tr class="memdesc:gac7f76a04b6f6873c52ad176d58901fe9"><td class="mdescLeft">&#160;</td><td class="mdescRight">Performs a master interrupt non-blocking transfer on the I2C bus.  <a href="#gac7f76a04b6f6873c52ad176d58901fe9">More...</a><br/></td></tr>
<tr class="separator:gac7f76a04b6f6873c52ad176d58901fe9"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga7d720842e68161d2d52d56d119f20665"><td class="memItemLeft" align="right" valign="top">status_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#ga7d720842e68161d2d52d56d119f20665">I2C_MasterTransferGetCount</a> (I2C_Type *base, i2c_master_handle_t *handle, size_t *count)</td></tr>
<tr class="memdesc:ga7d720842e68161d2d52d56d119f20665"><td class="mdescLeft">&#160;</td><td class="mdescRight">Gets the master transfer status during a interrupt non-blocking transfer.  <a href="#ga7d720842e68161d2d52d56d119f20665">More...</a><br/></td></tr>
<tr class="separator:ga7d720842e68161d2d52d56d119f20665"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga77c9f9c8bc0fe71bbcd9d479f51f8044"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#ga77c9f9c8bc0fe71bbcd9d479f51f8044">I2C_MasterTransferAbort</a> (I2C_Type *base, i2c_master_handle_t *handle)</td></tr>
<tr class="memdesc:ga77c9f9c8bc0fe71bbcd9d479f51f8044"><td class="mdescLeft">&#160;</td><td class="mdescRight">Aborts an interrupt non-blocking transfer early.  <a href="#ga77c9f9c8bc0fe71bbcd9d479f51f8044">More...</a><br/></td></tr>
<tr class="separator:ga77c9f9c8bc0fe71bbcd9d479f51f8044"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gad091cd1857d2bd8ce64583739b3a35d5"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#gad091cd1857d2bd8ce64583739b3a35d5">I2C_MasterTransferHandleIRQ</a> (I2C_Type *base, void *i2cHandle)</td></tr>
<tr class="memdesc:gad091cd1857d2bd8ce64583739b3a35d5"><td class="mdescLeft">&#160;</td><td class="mdescRight">Master interrupt handler.  <a href="#gad091cd1857d2bd8ce64583739b3a35d5">More...</a><br/></td></tr>
<tr class="separator:gad091cd1857d2bd8ce64583739b3a35d5"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gac9b90f575d92ff8ad3cc350a5c8ad1b9"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#gac9b90f575d92ff8ad3cc350a5c8ad1b9">I2C_SlaveTransferCreateHandle</a> (I2C_Type *base, i2c_slave_handle_t *handle, <a class="el" href="group__i2c__driver.html#ga974310ded85af5ef341811d542db650c">i2c_slave_transfer_callback_t</a> callback, void *userData)</td></tr>
<tr class="memdesc:gac9b90f575d92ff8ad3cc350a5c8ad1b9"><td class="mdescLeft">&#160;</td><td class="mdescRight">Initializes the I2C handle which is used in transactional functions.  <a href="#gac9b90f575d92ff8ad3cc350a5c8ad1b9">More...</a><br/></td></tr>
<tr class="separator:gac9b90f575d92ff8ad3cc350a5c8ad1b9"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gaa387d81ea08a9d4b39cfeb3dfec505f7"><td class="memItemLeft" align="right" valign="top">status_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#gaa387d81ea08a9d4b39cfeb3dfec505f7">I2C_SlaveTransferNonBlocking</a> (I2C_Type *base, i2c_slave_handle_t *handle, uint32_t eventMask)</td></tr>
<tr class="memdesc:gaa387d81ea08a9d4b39cfeb3dfec505f7"><td class="mdescLeft">&#160;</td><td class="mdescRight">Starts accepting slave transfers.  <a href="#gaa387d81ea08a9d4b39cfeb3dfec505f7">More...</a><br/></td></tr>
<tr class="separator:gaa387d81ea08a9d4b39cfeb3dfec505f7"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga5ae9f5e6e854d14d33ba3029128bd6f0"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#ga5ae9f5e6e854d14d33ba3029128bd6f0">I2C_SlaveTransferAbort</a> (I2C_Type *base, i2c_slave_handle_t *handle)</td></tr>
<tr class="memdesc:ga5ae9f5e6e854d14d33ba3029128bd6f0"><td class="mdescLeft">&#160;</td><td class="mdescRight">Aborts the slave transfer.  <a href="#ga5ae9f5e6e854d14d33ba3029128bd6f0">More...</a><br/></td></tr>
<tr class="separator:ga5ae9f5e6e854d14d33ba3029128bd6f0"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gabf38a498bd3527ea0b7cc947ae71e17e"><td class="memItemLeft" align="right" valign="top">status_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#gabf38a498bd3527ea0b7cc947ae71e17e">I2C_SlaveTransferGetCount</a> (I2C_Type *base, i2c_slave_handle_t *handle, size_t *count)</td></tr>
<tr class="memdesc:gabf38a498bd3527ea0b7cc947ae71e17e"><td class="mdescLeft">&#160;</td><td class="mdescRight">Gets the slave transfer remaining bytes during a interrupt non-blocking transfer.  <a href="#gabf38a498bd3527ea0b7cc947ae71e17e">More...</a><br/></td></tr>
<tr class="separator:gabf38a498bd3527ea0b7cc947ae71e17e"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga097c0b20503381de44cccba311dcf236"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#ga097c0b20503381de44cccba311dcf236">I2C_SlaveTransferHandleIRQ</a> (I2C_Type *base, void *i2cHandle)</td></tr>
<tr class="memdesc:ga097c0b20503381de44cccba311dcf236"><td class="mdescLeft">&#160;</td><td class="mdescRight">Slave interrupt handler.  <a href="#ga097c0b20503381de44cccba311dcf236">More...</a><br/></td></tr>
<tr class="separator:ga097c0b20503381de44cccba311dcf236"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<hr/><h2 class="groupheader">Data Structure Documentation</h2>
<a name="structi2c__master__config__t" id="structi2c__master__config__t"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">struct i2c_master_config_t</td>
        </tr>
      </table>
</div><div class="memdoc">
<div class="textblock"></div><table class="memberdecls">
<tr><td colspan="2"><h3>Data Fields</h3></td></tr>
<tr class="memitem:a2419131a10906475fd31950f17ac8895"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#a2419131a10906475fd31950f17ac8895">enableMaster</a></td></tr>
<tr class="memdesc:a2419131a10906475fd31950f17ac8895"><td class="mdescLeft">&#160;</td><td class="mdescRight">Enables the I2C peripheral at initialization time.  <a href="#a2419131a10906475fd31950f17ac8895">More...</a><br/></td></tr>
<tr class="separator:a2419131a10906475fd31950f17ac8895"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a2186844dc87bcde999fc12005f4c550a"><td class="memItemLeft" align="right" valign="top">uint32_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#a2186844dc87bcde999fc12005f4c550a">baudRate_Bps</a></td></tr>
<tr class="memdesc:a2186844dc87bcde999fc12005f4c550a"><td class="mdescLeft">&#160;</td><td class="mdescRight">Baud rate configuration of I2C peripheral.  <a href="#a2186844dc87bcde999fc12005f4c550a">More...</a><br/></td></tr>
<tr class="separator:a2186844dc87bcde999fc12005f4c550a"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<h4 class="groupheader">Field Documentation</h4>
<a class="anchor" id="a2419131a10906475fd31950f17ac8895"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">bool i2c_master_config_t::enableMaster</td>
        </tr>
      </table>
</div><div class="memdoc">

</div>
</div>
<a class="anchor" id="a2186844dc87bcde999fc12005f4c550a"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">uint32_t i2c_master_config_t::baudRate_Bps</td>
        </tr>
      </table>
</div><div class="memdoc">

</div>
</div>

</div>
</div>
<a name="structi2c__master__transfer__t" id="structi2c__master__transfer__t"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">struct i2c_master_transfer_t</td>
        </tr>
      </table>
</div><div class="memdoc">
<div class="textblock"></div><table class="memberdecls">
<tr><td colspan="2"><h3>Data Fields</h3></td></tr>
<tr class="memitem:a8835787e1b0f9a4b8868e7cbe53e45d5"><td class="memItemLeft" align="right" valign="top">uint32_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#a8835787e1b0f9a4b8868e7cbe53e45d5">flags</a></td></tr>
<tr class="memdesc:a8835787e1b0f9a4b8868e7cbe53e45d5"><td class="mdescLeft">&#160;</td><td class="mdescRight">A transfer flag which controls the transfer.  <a href="#a8835787e1b0f9a4b8868e7cbe53e45d5">More...</a><br/></td></tr>
<tr class="separator:a8835787e1b0f9a4b8868e7cbe53e45d5"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a3b9c4ae818b1194955db51de0f67795f"><td class="memItemLeft" align="right" valign="top">uint8_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#a3b9c4ae818b1194955db51de0f67795f">slaveAddress</a></td></tr>
<tr class="memdesc:a3b9c4ae818b1194955db51de0f67795f"><td class="mdescLeft">&#160;</td><td class="mdescRight">7-bit slave address.  <a href="#a3b9c4ae818b1194955db51de0f67795f">More...</a><br/></td></tr>
<tr class="separator:a3b9c4ae818b1194955db51de0f67795f"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ac5b89dc9115b7760431c981e0c1fd443"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__i2c__driver.html#gab49c827b45635206f06e5737606e4611">i2c_direction_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#ac5b89dc9115b7760431c981e0c1fd443">direction</a></td></tr>
<tr class="memdesc:ac5b89dc9115b7760431c981e0c1fd443"><td class="mdescLeft">&#160;</td><td class="mdescRight">A transfer direction, read or write.  <a href="#ac5b89dc9115b7760431c981e0c1fd443">More...</a><br/></td></tr>
<tr class="separator:ac5b89dc9115b7760431c981e0c1fd443"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ae7facb612714785d4e143e57d47a5af3"><td class="memItemLeft" align="right" valign="top">uint32_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#ae7facb612714785d4e143e57d47a5af3">subaddress</a></td></tr>
<tr class="memdesc:ae7facb612714785d4e143e57d47a5af3"><td class="mdescLeft">&#160;</td><td class="mdescRight">A sub address.  <a href="#ae7facb612714785d4e143e57d47a5af3">More...</a><br/></td></tr>
<tr class="separator:ae7facb612714785d4e143e57d47a5af3"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a9c08797f65f0faac78f44ac038c45c38"><td class="memItemLeft" align="right" valign="top">uint8_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#a9c08797f65f0faac78f44ac038c45c38">subaddressSize</a></td></tr>
<tr class="memdesc:a9c08797f65f0faac78f44ac038c45c38"><td class="mdescLeft">&#160;</td><td class="mdescRight">A size of the command buffer.  <a href="#a9c08797f65f0faac78f44ac038c45c38">More...</a><br/></td></tr>
<tr class="separator:a9c08797f65f0faac78f44ac038c45c38"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a0b4fa495c845d29fe6eaad7350337943"><td class="memItemLeft" align="right" valign="top">uint8_t *volatile&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#a0b4fa495c845d29fe6eaad7350337943">data</a></td></tr>
<tr class="memdesc:a0b4fa495c845d29fe6eaad7350337943"><td class="mdescLeft">&#160;</td><td class="mdescRight">A transfer buffer.  <a href="#a0b4fa495c845d29fe6eaad7350337943">More...</a><br/></td></tr>
<tr class="separator:a0b4fa495c845d29fe6eaad7350337943"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a071d26432bea08e4bf76bb4eb8805770"><td class="memItemLeft" align="right" valign="top">volatile size_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#a071d26432bea08e4bf76bb4eb8805770">dataSize</a></td></tr>
<tr class="memdesc:a071d26432bea08e4bf76bb4eb8805770"><td class="mdescLeft">&#160;</td><td class="mdescRight">A transfer size.  <a href="#a071d26432bea08e4bf76bb4eb8805770">More...</a><br/></td></tr>
<tr class="separator:a071d26432bea08e4bf76bb4eb8805770"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<h4 class="groupheader">Field Documentation</h4>
<a class="anchor" id="a8835787e1b0f9a4b8868e7cbe53e45d5"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">uint32_t i2c_master_transfer_t::flags</td>
        </tr>
      </table>
</div><div class="memdoc">

</div>
</div>
<a class="anchor" id="a3b9c4ae818b1194955db51de0f67795f"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">uint8_t i2c_master_transfer_t::slaveAddress</td>
        </tr>
      </table>
</div><div class="memdoc">

</div>
</div>
<a class="anchor" id="ac5b89dc9115b7760431c981e0c1fd443"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__i2c__driver.html#gab49c827b45635206f06e5737606e4611">i2c_direction_t</a> i2c_master_transfer_t::direction</td>
        </tr>
      </table>
</div><div class="memdoc">

</div>
</div>
<a class="anchor" id="ae7facb612714785d4e143e57d47a5af3"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">uint32_t i2c_master_transfer_t::subaddress</td>
        </tr>
      </table>
</div><div class="memdoc">
<p>Transferred MSB first. </p>

</div>
</div>
<a class="anchor" id="a9c08797f65f0faac78f44ac038c45c38"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">uint8_t i2c_master_transfer_t::subaddressSize</td>
        </tr>
      </table>
</div><div class="memdoc">

</div>
</div>
<a class="anchor" id="a0b4fa495c845d29fe6eaad7350337943"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">uint8_t* volatile i2c_master_transfer_t::data</td>
        </tr>
      </table>
</div><div class="memdoc">

</div>
</div>
<a class="anchor" id="a071d26432bea08e4bf76bb4eb8805770"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">volatile size_t i2c_master_transfer_t::dataSize</td>
        </tr>
      </table>
</div><div class="memdoc">

</div>
</div>

</div>
</div>
<a name="struct__i2c__master__handle" id="struct__i2c__master__handle"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">struct _i2c_master_handle</td>
        </tr>
      </table>
</div><div class="memdoc">
<div class="textblock"><p>I2C master handle typedef.</p>
</div><table class="memberdecls">
<tr><td colspan="2"><h3>Data Fields</h3></td></tr>
<tr class="memitem:a6858d3525f762d7aded20e6c95eb19fc"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__i2c__driver.html#structi2c__master__transfer__t">i2c_master_transfer_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#a6858d3525f762d7aded20e6c95eb19fc">transfer</a></td></tr>
<tr class="memdesc:a6858d3525f762d7aded20e6c95eb19fc"><td class="mdescLeft">&#160;</td><td class="mdescRight">I2C master transfer copy.  <a href="#a6858d3525f762d7aded20e6c95eb19fc">More...</a><br/></td></tr>
<tr class="separator:a6858d3525f762d7aded20e6c95eb19fc"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a5f6e3613a1fe8c3534a31526b1a34647"><td class="memItemLeft" align="right" valign="top">size_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#a5f6e3613a1fe8c3534a31526b1a34647">transferSize</a></td></tr>
<tr class="memdesc:a5f6e3613a1fe8c3534a31526b1a34647"><td class="mdescLeft">&#160;</td><td class="mdescRight">Total bytes to be transferred.  <a href="#a5f6e3613a1fe8c3534a31526b1a34647">More...</a><br/></td></tr>
<tr class="separator:a5f6e3613a1fe8c3534a31526b1a34647"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:add7ec18bc8239c5c87ffcec2fbcf5dd8"><td class="memItemLeft" align="right" valign="top">uint8_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#add7ec18bc8239c5c87ffcec2fbcf5dd8">state</a></td></tr>
<tr class="memdesc:add7ec18bc8239c5c87ffcec2fbcf5dd8"><td class="mdescLeft">&#160;</td><td class="mdescRight">A transfer state maintained during transfer.  <a href="#add7ec18bc8239c5c87ffcec2fbcf5dd8">More...</a><br/></td></tr>
<tr class="separator:add7ec18bc8239c5c87ffcec2fbcf5dd8"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a15b84b8a94c2b2e5ace0a695c79edd84"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__i2c__driver.html#ga1c6e059706357c744c165ce7ecd1c185">i2c_master_transfer_callback_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#a15b84b8a94c2b2e5ace0a695c79edd84">completionCallback</a></td></tr>
<tr class="memdesc:a15b84b8a94c2b2e5ace0a695c79edd84"><td class="mdescLeft">&#160;</td><td class="mdescRight">A callback function called when the transfer is finished.  <a href="#a15b84b8a94c2b2e5ace0a695c79edd84">More...</a><br/></td></tr>
<tr class="separator:a15b84b8a94c2b2e5ace0a695c79edd84"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aad7df570c53adb2e80acd2ba0d39d109"><td class="memItemLeft" align="right" valign="top">void *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#aad7df570c53adb2e80acd2ba0d39d109">userData</a></td></tr>
<tr class="memdesc:aad7df570c53adb2e80acd2ba0d39d109"><td class="mdescLeft">&#160;</td><td class="mdescRight">A callback parameter passed to the callback function.  <a href="#aad7df570c53adb2e80acd2ba0d39d109">More...</a><br/></td></tr>
<tr class="separator:aad7df570c53adb2e80acd2ba0d39d109"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<h4 class="groupheader">Field Documentation</h4>
<a class="anchor" id="a6858d3525f762d7aded20e6c95eb19fc"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__i2c__driver.html#structi2c__master__transfer__t">i2c_master_transfer_t</a> i2c_master_handle_t::transfer</td>
        </tr>
      </table>
</div><div class="memdoc">

</div>
</div>
<a class="anchor" id="a5f6e3613a1fe8c3534a31526b1a34647"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">size_t i2c_master_handle_t::transferSize</td>
        </tr>
      </table>
</div><div class="memdoc">

</div>
</div>
<a class="anchor" id="add7ec18bc8239c5c87ffcec2fbcf5dd8"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">uint8_t i2c_master_handle_t::state</td>
        </tr>
      </table>
</div><div class="memdoc">

</div>
</div>
<a class="anchor" id="a15b84b8a94c2b2e5ace0a695c79edd84"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__i2c__driver.html#ga1c6e059706357c744c165ce7ecd1c185">i2c_master_transfer_callback_t</a> i2c_master_handle_t::completionCallback</td>
        </tr>
      </table>
</div><div class="memdoc">

</div>
</div>
<a class="anchor" id="aad7df570c53adb2e80acd2ba0d39d109"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void* i2c_master_handle_t::userData</td>
        </tr>
      </table>
</div><div class="memdoc">

</div>
</div>

</div>
</div>
<a name="structi2c__slave__config__t" id="structi2c__slave__config__t"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">struct i2c_slave_config_t</td>
        </tr>
      </table>
</div><div class="memdoc">
<div class="textblock"></div><table class="memberdecls">
<tr><td colspan="2"><h3>Data Fields</h3></td></tr>
<tr class="memitem:a92d20835618a946b8f7702455877ef7a"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#a92d20835618a946b8f7702455877ef7a">enableSlave</a></td></tr>
<tr class="memdesc:a92d20835618a946b8f7702455877ef7a"><td class="mdescLeft">&#160;</td><td class="mdescRight">Enables the I2C peripheral at initialization time.  <a href="#a92d20835618a946b8f7702455877ef7a">More...</a><br/></td></tr>
<tr class="separator:a92d20835618a946b8f7702455877ef7a"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a05851e26565e2b89bd49ef230cc397be"><td class="memItemLeft" align="right" valign="top">uint16_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#a05851e26565e2b89bd49ef230cc397be">slaveAddress</a></td></tr>
<tr class="memdesc:a05851e26565e2b89bd49ef230cc397be"><td class="mdescLeft">&#160;</td><td class="mdescRight">A slave address configuration.  <a href="#a05851e26565e2b89bd49ef230cc397be">More...</a><br/></td></tr>
<tr class="separator:a05851e26565e2b89bd49ef230cc397be"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<h4 class="groupheader">Field Documentation</h4>
<a class="anchor" id="a92d20835618a946b8f7702455877ef7a"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">bool i2c_slave_config_t::enableSlave</td>
        </tr>
      </table>
</div><div class="memdoc">

</div>
</div>
<a class="anchor" id="a05851e26565e2b89bd49ef230cc397be"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">uint16_t i2c_slave_config_t::slaveAddress</td>
        </tr>
      </table>
</div><div class="memdoc">

</div>
</div>

</div>
</div>
<a name="structi2c__slave__transfer__t" id="structi2c__slave__transfer__t"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">struct i2c_slave_transfer_t</td>
        </tr>
      </table>
</div><div class="memdoc">
<div class="textblock"></div><table class="memberdecls">
<tr><td colspan="2"><h3>Data Fields</h3></td></tr>
<tr class="memitem:ad0a9e837e9df16d89bab98a78af5bd10"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__i2c__driver.html#gac53e5c96a2eed1b5a95b7d84be48f4ac">i2c_slave_transfer_event_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#ad0a9e837e9df16d89bab98a78af5bd10">event</a></td></tr>
<tr class="memdesc:ad0a9e837e9df16d89bab98a78af5bd10"><td class="mdescLeft">&#160;</td><td class="mdescRight">A reason that the callback is invoked.  <a href="#ad0a9e837e9df16d89bab98a78af5bd10">More...</a><br/></td></tr>
<tr class="separator:ad0a9e837e9df16d89bab98a78af5bd10"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ae8dab4de2445f3094b6baef3712a80a9"><td class="memItemLeft" align="right" valign="top">uint8_t *volatile&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#ae8dab4de2445f3094b6baef3712a80a9">data</a></td></tr>
<tr class="memdesc:ae8dab4de2445f3094b6baef3712a80a9"><td class="mdescLeft">&#160;</td><td class="mdescRight">A transfer buffer.  <a href="#ae8dab4de2445f3094b6baef3712a80a9">More...</a><br/></td></tr>
<tr class="separator:ae8dab4de2445f3094b6baef3712a80a9"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a96d433bce400dfc4917343f2b07e8b1d"><td class="memItemLeft" align="right" valign="top">volatile size_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#a96d433bce400dfc4917343f2b07e8b1d">dataSize</a></td></tr>
<tr class="memdesc:a96d433bce400dfc4917343f2b07e8b1d"><td class="mdescLeft">&#160;</td><td class="mdescRight">A transfer size.  <a href="#a96d433bce400dfc4917343f2b07e8b1d">More...</a><br/></td></tr>
<tr class="separator:a96d433bce400dfc4917343f2b07e8b1d"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a35adbf64ca65dd2c1b52f9260f5b9e90"><td class="memItemLeft" align="right" valign="top">status_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#a35adbf64ca65dd2c1b52f9260f5b9e90">completionStatus</a></td></tr>
<tr class="memdesc:a35adbf64ca65dd2c1b52f9260f5b9e90"><td class="mdescLeft">&#160;</td><td class="mdescRight">Success or error code describing how the transfer completed.  <a href="#a35adbf64ca65dd2c1b52f9260f5b9e90">More...</a><br/></td></tr>
<tr class="separator:a35adbf64ca65dd2c1b52f9260f5b9e90"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a0394563c8d0f9eeeecd242a65cee2ad4"><td class="memItemLeft" align="right" valign="top">size_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#a0394563c8d0f9eeeecd242a65cee2ad4">transferredCount</a></td></tr>
<tr class="memdesc:a0394563c8d0f9eeeecd242a65cee2ad4"><td class="mdescLeft">&#160;</td><td class="mdescRight">A number of bytes actually transferred since the start or since the last repeated start.  <a href="#a0394563c8d0f9eeeecd242a65cee2ad4">More...</a><br/></td></tr>
<tr class="separator:a0394563c8d0f9eeeecd242a65cee2ad4"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<h4 class="groupheader">Field Documentation</h4>
<a class="anchor" id="ad0a9e837e9df16d89bab98a78af5bd10"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__i2c__driver.html#gac53e5c96a2eed1b5a95b7d84be48f4ac">i2c_slave_transfer_event_t</a> i2c_slave_transfer_t::event</td>
        </tr>
      </table>
</div><div class="memdoc">

</div>
</div>
<a class="anchor" id="ae8dab4de2445f3094b6baef3712a80a9"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">uint8_t* volatile i2c_slave_transfer_t::data</td>
        </tr>
      </table>
</div><div class="memdoc">

</div>
</div>
<a class="anchor" id="a96d433bce400dfc4917343f2b07e8b1d"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">volatile size_t i2c_slave_transfer_t::dataSize</td>
        </tr>
      </table>
</div><div class="memdoc">

</div>
</div>
<a class="anchor" id="a35adbf64ca65dd2c1b52f9260f5b9e90"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">status_t i2c_slave_transfer_t::completionStatus</td>
        </tr>
      </table>
</div><div class="memdoc">
<p>Only applies for <a class="el" href="group__i2c__driver.html#ggac53e5c96a2eed1b5a95b7d84be48f4aca38cca3cd668e73f51b8e574835d419df" title="A stop was detected or finished transfer, completing the transfer. ">kI2C_SlaveCompletionEvent</a>. </p>

</div>
</div>
<a class="anchor" id="a0394563c8d0f9eeeecd242a65cee2ad4"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">size_t i2c_slave_transfer_t::transferredCount</td>
        </tr>
      </table>
</div><div class="memdoc">

</div>
</div>

</div>
</div>
<a name="struct__i2c__slave__handle" id="struct__i2c__slave__handle"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">struct _i2c_slave_handle</td>
        </tr>
      </table>
</div><div class="memdoc">
<div class="textblock"><p>I2C slave handle typedef.</p>
</div><table class="memberdecls">
<tr><td colspan="2"><h3>Data Fields</h3></td></tr>
<tr class="memitem:a05e28c7ba871cce0a3dd1bad4b768336"><td class="memItemLeft" align="right" valign="top">volatile uint8_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#a05e28c7ba871cce0a3dd1bad4b768336">state</a></td></tr>
<tr class="memdesc:a05e28c7ba871cce0a3dd1bad4b768336"><td class="mdescLeft">&#160;</td><td class="mdescRight">A transfer state maintained during transfer.  <a href="#a05e28c7ba871cce0a3dd1bad4b768336">More...</a><br/></td></tr>
<tr class="separator:a05e28c7ba871cce0a3dd1bad4b768336"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a49f6e4eb57b2158f3886f47e6c84d1b9"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__i2c__driver.html#structi2c__slave__transfer__t">i2c_slave_transfer_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#a49f6e4eb57b2158f3886f47e6c84d1b9">transfer</a></td></tr>
<tr class="memdesc:a49f6e4eb57b2158f3886f47e6c84d1b9"><td class="mdescLeft">&#160;</td><td class="mdescRight">I2C slave transfer copy.  <a href="#a49f6e4eb57b2158f3886f47e6c84d1b9">More...</a><br/></td></tr>
<tr class="separator:a49f6e4eb57b2158f3886f47e6c84d1b9"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a8ab7d35b42a241c05ddb4c18f8d1e522"><td class="memItemLeft" align="right" valign="top">uint32_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#a8ab7d35b42a241c05ddb4c18f8d1e522">eventMask</a></td></tr>
<tr class="memdesc:a8ab7d35b42a241c05ddb4c18f8d1e522"><td class="mdescLeft">&#160;</td><td class="mdescRight">A mask of enabled events.  <a href="#a8ab7d35b42a241c05ddb4c18f8d1e522">More...</a><br/></td></tr>
<tr class="separator:a8ab7d35b42a241c05ddb4c18f8d1e522"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a7229e894f762ead4bd08b4add49e6bc2"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__i2c__driver.html#ga974310ded85af5ef341811d542db650c">i2c_slave_transfer_callback_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#a7229e894f762ead4bd08b4add49e6bc2">callback</a></td></tr>
<tr class="memdesc:a7229e894f762ead4bd08b4add49e6bc2"><td class="mdescLeft">&#160;</td><td class="mdescRight">A callback function called at the transfer event.  <a href="#a7229e894f762ead4bd08b4add49e6bc2">More...</a><br/></td></tr>
<tr class="separator:a7229e894f762ead4bd08b4add49e6bc2"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a98ea5e99278b386e2ddb99d45a9750ee"><td class="memItemLeft" align="right" valign="top">void *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__i2c__driver.html#a98ea5e99278b386e2ddb99d45a9750ee">userData</a></td></tr>
<tr class="memdesc:a98ea5e99278b386e2ddb99d45a9750ee"><td class="mdescLeft">&#160;</td><td class="mdescRight">A callback parameter passed to the callback.  <a href="#a98ea5e99278b386e2ddb99d45a9750ee">More...</a><br/></td></tr>
<tr class="separator:a98ea5e99278b386e2ddb99d45a9750ee"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<h4 class="groupheader">Field Documentation</h4>
<a class="anchor" id="a05e28c7ba871cce0a3dd1bad4b768336"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">volatile uint8_t i2c_slave_handle_t::state</td>
        </tr>
      </table>
</div><div class="memdoc">

</div>
</div>
<a class="anchor" id="a49f6e4eb57b2158f3886f47e6c84d1b9"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__i2c__driver.html#structi2c__slave__transfer__t">i2c_slave_transfer_t</a> i2c_slave_handle_t::transfer</td>
        </tr>
      </table>
</div><div class="memdoc">

</div>
</div>
<a class="anchor" id="a8ab7d35b42a241c05ddb4c18f8d1e522"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">uint32_t i2c_slave_handle_t::eventMask</td>
        </tr>
      </table>
</div><div class="memdoc">

</div>
</div>
<a class="anchor" id="a7229e894f762ead4bd08b4add49e6bc2"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__i2c__driver.html#ga974310ded85af5ef341811d542db650c">i2c_slave_transfer_callback_t</a> i2c_slave_handle_t::callback</td>
        </tr>
      </table>
</div><div class="memdoc">

</div>
</div>
<a class="anchor" id="a98ea5e99278b386e2ddb99d45a9750ee"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void* i2c_slave_handle_t::userData</td>
        </tr>
      </table>
</div><div class="memdoc">

</div>
</div>

</div>
</div>
<h2 class="groupheader">Macro Definition Documentation</h2>
<a class="anchor" id="ga60fdaec284298758a650ce1122aef231"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define FSL_I2C_DRIVER_VERSION&#160;&#160;&#160;(MAKE_VERSION(2, 0, 0))</td>
        </tr>
      </table>
</div><div class="memdoc">

</div>
</div>
<h2 class="groupheader">Typedef Documentation</h2>
<a class="anchor" id="ga1c6e059706357c744c165ce7ecd1c185"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">typedef void(* i2c_master_transfer_callback_t)(I2C_Type *base, i2c_master_handle_t *handle, status_t status, void *userData)</td>
        </tr>
      </table>
</div><div class="memdoc">

</div>
</div>
<a class="anchor" id="ga974310ded85af5ef341811d542db650c"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">typedef void(* i2c_slave_transfer_callback_t)(I2C_Type *base, <a class="el" href="group__i2c__driver.html#structi2c__slave__transfer__t">i2c_slave_transfer_t</a> *xfer, void *userData)</td>
        </tr>
      </table>
</div><div class="memdoc">

</div>
</div>
<h2 class="groupheader">Enumeration Type Documentation</h2>
<a class="anchor" id="ga7cc91c89125c25a88e463a9e8550b284"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">enum <a class="el" href="group__i2c__driver.html#ga7cc91c89125c25a88e463a9e8550b284">_i2c_status</a></td>
        </tr>
      </table>
</div><div class="memdoc">
<table class="fieldtable">
<tr><th colspan="2">Enumerator</th></tr><tr><td class="fieldname"><em><a class="anchor" id="gga7cc91c89125c25a88e463a9e8550b284a49091894b590d7e479605bf113918952"></a>kStatus_I2C_Busy</em>&nbsp;</td><td class="fielddoc">
<p>I2C is busy with current transfer. </p>
</td></tr>
<tr><td class="fieldname"><em><a class="anchor" id="gga7cc91c89125c25a88e463a9e8550b284a628d242f7bc0e3d5949c7f73eafaa508"></a>kStatus_I2C_Idle</em>&nbsp;</td><td class="fielddoc">
<p>Bus is Idle. </p>
</td></tr>
<tr><td class="fieldname"><em><a class="anchor" id="gga7cc91c89125c25a88e463a9e8550b284a72fd33d0b5263a63766e62f71d16be00"></a>kStatus_I2C_Nak</em>&nbsp;</td><td class="fielddoc">
<p>NAK received during transfer. </p>
</td></tr>
<tr><td class="fieldname"><em><a class="anchor" id="gga7cc91c89125c25a88e463a9e8550b284a139b52cc3305ec2c06d0ac94313c221f"></a>kStatus_I2C_ArbitrationLost</em>&nbsp;</td><td class="fielddoc">
<p>Arbitration lost during transfer. </p>
</td></tr>
<tr><td class="fieldname"><em><a class="anchor" id="gga7cc91c89125c25a88e463a9e8550b284a81ad7cc198436cabbe91ea55c5288747"></a>kStatus_I2C_Timeout</em>&nbsp;</td><td class="fielddoc">
<p>Wait event timeout. </p>
</td></tr>
<tr><td class="fieldname"><em><a class="anchor" id="gga7cc91c89125c25a88e463a9e8550b284adf7437bfedcc0d57338ed33f1be5c805"></a>kStatus_I2C_Addr_Nak</em>&nbsp;</td><td class="fielddoc">
<p>NAK received during the address probe. </p>
</td></tr>
</table>

</div>
</div>
<a class="anchor" id="ga1f1337bbe9d0b184d9dcee31f9ebade2"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">enum <a class="el" href="group__i2c__driver.html#ga1f1337bbe9d0b184d9dcee31f9ebade2">_i2c_flags</a></td>
        </tr>
      </table>
</div><div class="memdoc">
<p>The following status register flags can be cleared:</p>
<ul>
<li><a class="el" href="group__i2c__driver.html#gga1f1337bbe9d0b184d9dcee31f9ebade2a39fab5ef04e74d00ef4c4574899ab589" title="I2C arbitration lost flag. ">kI2C_ArbitrationLostFlag</a></li>
<li><a class="el" href="group__i2c__driver.html#gga1f1337bbe9d0b184d9dcee31f9ebade2a647d0b1d1f9514ad483bef3ea3926c3b" title="I2C interrupt pending flag. ">kI2C_IntPendingFlag</a></li>
</ul>
<dl class="section note"><dt>Note</dt><dd>These enumerations are meant to be OR'd together to form a bit mask. </dd></dl>
<table class="fieldtable">
<tr><th colspan="2">Enumerator</th></tr><tr><td class="fieldname"><em><a class="anchor" id="gga1f1337bbe9d0b184d9dcee31f9ebade2a4c3c2928e17ddbfbc1c346c6b9a8dccd"></a>kI2C_ReceiveNakFlag</em>&nbsp;</td><td class="fielddoc">
<p>I2C receive NAK flag. </p>
</td></tr>
<tr><td class="fieldname"><em><a class="anchor" id="gga1f1337bbe9d0b184d9dcee31f9ebade2a647d0b1d1f9514ad483bef3ea3926c3b"></a>kI2C_IntPendingFlag</em>&nbsp;</td><td class="fielddoc">
<p>I2C interrupt pending flag. </p>
</td></tr>
<tr><td class="fieldname"><em><a class="anchor" id="gga1f1337bbe9d0b184d9dcee31f9ebade2a249f698970909f33b1b96139c05bd969"></a>kI2C_TransferDirectionFlag</em>&nbsp;</td><td class="fielddoc">
<p>I2C transfer direction flag. </p>
</td></tr>
<tr><td class="fieldname"><em><a class="anchor" id="gga1f1337bbe9d0b184d9dcee31f9ebade2a39fab5ef04e74d00ef4c4574899ab589"></a>kI2C_ArbitrationLostFlag</em>&nbsp;</td><td class="fielddoc">
<p>I2C arbitration lost flag. </p>
</td></tr>
<tr><td class="fieldname"><em><a class="anchor" id="gga1f1337bbe9d0b184d9dcee31f9ebade2a37fb20742a15a63c1bc2551b997cdcff"></a>kI2C_BusBusyFlag</em>&nbsp;</td><td class="fielddoc">
<p>I2C bus busy flag. </p>
</td></tr>
<tr><td class="fieldname"><em><a class="anchor" id="gga1f1337bbe9d0b184d9dcee31f9ebade2a10cd5797b1b8f809192423486a85d5fe"></a>kI2C_AddressMatchFlag</em>&nbsp;</td><td class="fielddoc">
<p>I2C address match flag. </p>
</td></tr>
<tr><td class="fieldname"><em><a class="anchor" id="gga1f1337bbe9d0b184d9dcee31f9ebade2adb8f10365dfc2a3e849f05173fa4d83e"></a>kI2C_TransferCompleteFlag</em>&nbsp;</td><td class="fielddoc">
<p>I2C transfer complete flag. </p>
</td></tr>
</table>

</div>
</div>
<a class="anchor" id="ga87c81dd985dad07dc26cb93125a94ec7"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">enum <a class="el" href="group__i2c__driver.html#ga87c81dd985dad07dc26cb93125a94ec7">_i2c_interrupt_enable</a></td>
        </tr>
      </table>
</div><div class="memdoc">
<table class="fieldtable">
<tr><th colspan="2">Enumerator</th></tr><tr><td class="fieldname"><em><a class="anchor" id="gga87c81dd985dad07dc26cb93125a94ec7a5526e27ef6e8317ba928849da890b3b2"></a>kI2C_GlobalInterruptEnable</em>&nbsp;</td><td class="fielddoc">
<p>I2C global interrupt. </p>
</td></tr>
</table>

</div>
</div>
<a class="anchor" id="gab49c827b45635206f06e5737606e4611"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">enum <a class="el" href="group__i2c__driver.html#gab49c827b45635206f06e5737606e4611">i2c_direction_t</a></td>
        </tr>
      </table>
</div><div class="memdoc">
<table class="fieldtable">
<tr><th colspan="2">Enumerator</th></tr><tr><td class="fieldname"><em><a class="anchor" id="ggab49c827b45635206f06e5737606e4611a93b476b469c2a4bfed5916b458ae9bb0"></a>kI2C_Write</em>&nbsp;</td><td class="fielddoc">
<p>Master transmits to the slave. </p>
</td></tr>
<tr><td class="fieldname"><em><a class="anchor" id="ggab49c827b45635206f06e5737606e4611a3a7bb24dc8d1c1be8925603eeafe9b30"></a>kI2C_Read</em>&nbsp;</td><td class="fielddoc">
<p>Master receives from the slave. </p>
</td></tr>
</table>

</div>
</div>
<a class="anchor" id="ga87ea07668194cfb46c7c368d2cb42433"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">enum <a class="el" href="group__i2c__driver.html#ga87ea07668194cfb46c7c368d2cb42433">_i2c_master_transfer_flags</a></td>
        </tr>
      </table>
</div><div class="memdoc">
<table class="fieldtable">
<tr><th colspan="2">Enumerator</th></tr><tr><td class="fieldname"><em><a class="anchor" id="gga87ea07668194cfb46c7c368d2cb42433ae80f7b768b1621e42ac965d3d23de5e2"></a>kI2C_TransferDefaultFlag</em>&nbsp;</td><td class="fielddoc">
<p>A transfer starts with a start signal, stops with a stop signal. </p>
</td></tr>
<tr><td class="fieldname"><em><a class="anchor" id="gga87ea07668194cfb46c7c368d2cb42433a5cb44bf860c0482c0ca0165cf0d31d8a"></a>kI2C_TransferNoStartFlag</em>&nbsp;</td><td class="fielddoc">
<p>A transfer starts without a start signal. </p>
</td></tr>
<tr><td class="fieldname"><em><a class="anchor" id="gga87ea07668194cfb46c7c368d2cb42433aadf112471ef12f194985a093cd9b9721"></a>kI2C_TransferRepeatedStartFlag</em>&nbsp;</td><td class="fielddoc">
<p>A transfer starts with a repeated start signal. </p>
</td></tr>
<tr><td class="fieldname"><em><a class="anchor" id="gga87ea07668194cfb46c7c368d2cb42433afb8aeea71b5b7475e3d3df86220db566"></a>kI2C_TransferNoStopFlag</em>&nbsp;</td><td class="fielddoc">
<p>A transfer ends without a stop signal. </p>
</td></tr>
</table>

</div>
</div>
<a class="anchor" id="gac53e5c96a2eed1b5a95b7d84be48f4ac"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">enum <a class="el" href="group__i2c__driver.html#gac53e5c96a2eed1b5a95b7d84be48f4ac">i2c_slave_transfer_event_t</a></td>
        </tr>
      </table>
</div><div class="memdoc">
<p>These event enumerations are used for two related purposes. First, a bit mask created by OR'ing together events is passed to <a class="el" href="group__i2c__driver.html#gaa387d81ea08a9d4b39cfeb3dfec505f7" title="Starts accepting slave transfers. ">I2C_SlaveTransferNonBlocking()</a> to specify which events to enable. Then, when the slave callback is invoked, it is passed the current event through its <em>transfer</em> parameter.</p>
<dl class="section note"><dt>Note</dt><dd>These enumerations are meant to be OR'd together to form a bit mask of events. </dd></dl>
<table class="fieldtable">
<tr><th colspan="2">Enumerator</th></tr><tr><td class="fieldname"><em><a class="anchor" id="ggac53e5c96a2eed1b5a95b7d84be48f4acacb1ae174dd6798a6fd79800a9e39a3c6"></a>kI2C_SlaveAddressMatchEvent</em>&nbsp;</td><td class="fielddoc">
<p>Received the slave address after a start or repeated start. </p>
</td></tr>
<tr><td class="fieldname"><em><a class="anchor" id="ggac53e5c96a2eed1b5a95b7d84be48f4aca2f85039a57379838909876a1d509b7aa"></a>kI2C_SlaveTransmitEvent</em>&nbsp;</td><td class="fielddoc">
<p>A callback is requested to provide data to transmit (slave-transmitter role). </p>
</td></tr>
<tr><td class="fieldname"><em><a class="anchor" id="ggac53e5c96a2eed1b5a95b7d84be48f4acaac8593e808a8137d1b5d3a51640779de"></a>kI2C_SlaveReceiveEvent</em>&nbsp;</td><td class="fielddoc">
<p>A callback is requested to provide a buffer in which to place received data (slave-receiver role). </p>
</td></tr>
<tr><td class="fieldname"><em><a class="anchor" id="ggac53e5c96a2eed1b5a95b7d84be48f4aca43c045da27fa60e7a0540c743eca4e79"></a>kI2C_SlaveTransmitAckEvent</em>&nbsp;</td><td class="fielddoc">
<p>A callback needs to either transmit an ACK or NACK. </p>
</td></tr>
<tr><td class="fieldname"><em><a class="anchor" id="ggac53e5c96a2eed1b5a95b7d84be48f4aca38cca3cd668e73f51b8e574835d419df"></a>kI2C_SlaveCompletionEvent</em>&nbsp;</td><td class="fielddoc">
<p>A stop was detected or finished transfer, completing the transfer. </p>
</td></tr>
<tr><td class="fieldname"><em><a class="anchor" id="ggac53e5c96a2eed1b5a95b7d84be48f4aca94b030ebdac378a84961893ae567bfbc"></a>kI2C_SlaveAllEvents</em>&nbsp;</td><td class="fielddoc">
<p>A bit mask of all available events. </p>
</td></tr>
</table>

</div>
</div>
<h2 class="groupheader">Function Documentation</h2>
<a class="anchor" id="ga29f967b3ae8487a36ba2a58deb01ccae"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void I2C_MasterInit </td>
          <td>(</td>
          <td class="paramtype">I2C_Type *&#160;</td>
          <td class="paramname"><em>base</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const <a class="el" href="group__i2c__driver.html#structi2c__master__config__t">i2c_master_config_t</a> *&#160;</td>
          <td class="paramname"><em>masterConfig</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>srcClock_Hz</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">
<p>Call this API to ungate the I2C clock and configure the I2C with master configuration.</p>
<dl class="section note"><dt>Note</dt><dd>This API should be called at the beginning of the application. Otherwise, any operation to the I2C module can cause a hard fault because the clock is not enabled. The configuration structure can be custom filled or it can be set with default values by using the <a class="el" href="group__i2c__driver.html#gad69f2d63ea756dda60749ff6b09f587d" title="Sets the I2C master configuration structure to default values. ">I2C_MasterGetDefaultConfig()</a>. After calling this API, the master is ready to transfer. This is an example. <div class="fragment"><div class="line">* <a class="code" href="group__i2c__driver.html#structi2c__master__config__t">i2c_master_config_t</a> config = {</div>
<div class="line">* .<a class="code" href="group__i2c__driver.html#a2419131a10906475fd31950f17ac8895">enableMaster</a> = <span class="keyword">true</span>,</div>
<div class="line">* .baudRate_Bps = 100000</div>
<div class="line">* };</div>
<div class="line">* <a class="code" href="group__i2c__driver.html#ga29f967b3ae8487a36ba2a58deb01ccae">I2C_MasterInit</a>(I2C0, &amp;config, 12000000U);</div>
<div class="line">* </div>
</div><!-- fragment --></dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>I2C base pointer </td></tr>
    <tr><td class="paramname">masterConfig</td><td>A pointer to the master configuration structure </td></tr>
    <tr><td class="paramname">srcClock_Hz</td><td>I2C peripheral clock frequency in Hz </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="gadcf7122f0a38d4d9da0f052fcb167957"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void I2C_MasterDeinit </td>
          <td>(</td>
          <td class="paramtype">I2C_Type *&#160;</td>
          <td class="paramname"><em>base</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">
<p>Call this API to gate the I2C clock. The I2C master module can't work unless the I2C_MasterInit is called. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>I2C base pointer </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="gad69f2d63ea756dda60749ff6b09f587d"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void I2C_MasterGetDefaultConfig </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="group__i2c__driver.html#structi2c__master__config__t">i2c_master_config_t</a> *&#160;</td>
          <td class="paramname"><em>masterConfig</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">
<p>The purpose of this API is to get the configuration structure initialized for use in the <a class="el" href="group__i2c__driver.html#ga29f967b3ae8487a36ba2a58deb01ccae" title="Initializes the I2C peripheral. ">I2C_MasterInit()</a>. Use the initialized structure unchanged in the <a class="el" href="group__i2c__driver.html#ga29f967b3ae8487a36ba2a58deb01ccae" title="Initializes the I2C peripheral. ">I2C_MasterInit()</a> or modify the structure before calling the <a class="el" href="group__i2c__driver.html#ga29f967b3ae8487a36ba2a58deb01ccae" title="Initializes the I2C peripheral. ">I2C_MasterInit()</a>. This is an example. </p>
<div class="fragment"><div class="line">* <a class="code" href="group__i2c__driver.html#structi2c__master__config__t">i2c_master_config_t</a> config;</div>
<div class="line">* <a class="code" href="group__i2c__driver.html#gad69f2d63ea756dda60749ff6b09f587d">I2C_MasterGetDefaultConfig</a>(&amp;config);</div>
<div class="line">* </div>
</div><!-- fragment --> <dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">masterConfig</td><td>A pointer to the master configuration structure. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="gae6e155a5aadb43d527418e2965e39123"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void I2C_SlaveInit </td>
          <td>(</td>
          <td class="paramtype">I2C_Type *&#160;</td>
          <td class="paramname"><em>base</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const <a class="el" href="group__i2c__driver.html#structi2c__slave__config__t">i2c_slave_config_t</a> *&#160;</td>
          <td class="paramname"><em>slaveConfig</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">
<p>Call this API to ungate the I2C clock and initialize the I2C with the slave configuration.</p>
<dl class="section note"><dt>Note</dt><dd>This API should be called at the beginning of the application. Otherwise, any operation to the I2C module can cause a hard fault because the clock is not enabled. The configuration structure can partly be set with default values by <a class="el" href="group__i2c__driver.html#ga7115f80e28b62bbbd3be1a2a918529ba" title="Sets the I2C slave configuration structure to default values. ">I2C_SlaveGetDefaultConfig()</a> or it can be custom filled by the user. This is an example. <div class="fragment"><div class="line">* <a class="code" href="group__i2c__driver.html#structi2c__slave__config__t">i2c_slave_config_t</a> config = {</div>
<div class="line">* .enableSlave = <span class="keyword">true</span>,</div>
<div class="line">* .slaveAddress = 0x1DU,</div>
<div class="line">* };</div>
<div class="line">* <a class="code" href="group__i2c__driver.html#gae6e155a5aadb43d527418e2965e39123">I2C_SlaveInit</a>(I2C0, &amp;config);</div>
<div class="line">* </div>
</div><!-- fragment --></dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>I2C base pointer </td></tr>
    <tr><td class="paramname">slaveConfig</td><td>A pointer to the slave configuration structure </td></tr>
    <tr><td class="paramname">srcClock_Hz</td><td>I2C peripheral clock frequency in Hz </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="gadb50014db29dd75ea2001fb7bc837e77"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void I2C_SlaveDeinit </td>
          <td>(</td>
          <td class="paramtype">I2C_Type *&#160;</td>
          <td class="paramname"><em>base</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">
<p>Calling this API gates the I2C clock. The I2C slave module can't work unless the I2C_SlaveInit is called to enable the clock. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>I2C base pointer </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="ga7115f80e28b62bbbd3be1a2a918529ba"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void I2C_SlaveGetDefaultConfig </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="group__i2c__driver.html#structi2c__slave__config__t">i2c_slave_config_t</a> *&#160;</td>
          <td class="paramname"><em>slaveConfig</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">
<p>The purpose of this API is to get the configuration structure initialized for use in the <a class="el" href="group__i2c__driver.html#gae6e155a5aadb43d527418e2965e39123" title="Initializes the I2C peripheral. ">I2C_SlaveInit()</a>. Modify fields of the structure before calling the <a class="el" href="group__i2c__driver.html#gae6e155a5aadb43d527418e2965e39123" title="Initializes the I2C peripheral. ">I2C_SlaveInit()</a>. This is an example. </p>
<div class="fragment"><div class="line">* <a class="code" href="group__i2c__driver.html#structi2c__slave__config__t">i2c_slave_config_t</a> config;</div>
<div class="line">* <a class="code" href="group__i2c__driver.html#ga7115f80e28b62bbbd3be1a2a918529ba">I2C_SlaveGetDefaultConfig</a>(&amp;config);</div>
<div class="line">* </div>
</div><!-- fragment --> <dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">slaveConfig</td><td>A pointer to the slave configuration structure. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="gaaaaab1e83cb8c6117046bdb5bcbf9ac6"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">static void I2C_Enable </td>
          <td>(</td>
          <td class="paramtype">I2C_Type *&#160;</td>
          <td class="paramname"><em>base</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool&#160;</td>
          <td class="paramname"><em>enable</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">static</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>I2C base pointer </td></tr>
    <tr><td class="paramname">enable</td><td>Pass true to enable and false to disable the module. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="ga8219cf80c3be6c15fc5035326b7f62dc"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">static uint32_t I2C_MasterGetStatusFlags </td>
          <td>(</td>
          <td class="paramtype">I2C_Type *&#160;</td>
          <td class="paramname"><em>base</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">static</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>I2C base pointer </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>status flag, use status flag to AND <a class="el" href="group__i2c__driver.html#ga1f1337bbe9d0b184d9dcee31f9ebade2" title="I2C peripheral flags. ">_i2c_flags</a> to get the related status. </dd></dl>

</div>
</div>
<a class="anchor" id="ga437271ffb955b77df0a5dee9ea80cc63"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">static void I2C_MasterClearStatusFlags </td>
          <td>(</td>
          <td class="paramtype">I2C_Type *&#160;</td>
          <td class="paramname"><em>base</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>statusMask</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">static</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>The following status register flags can be cleared kI2C_ArbitrationLostFlag and kI2C_IntPendingFlag.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>I2C base pointer </td></tr>
    <tr><td class="paramname">statusMask</td><td>The status flag mask, defined in type i2c_status_flag_t. The parameter can be any combination of the following values: <ul>
<li>kI2C_ArbitrationLostFlag </li>
<li>kI2C_IntPendingFlagFlag </li>
</ul>
</td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="gac2794e138d94d9b6a761c074ad0899cd"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">static uint32_t I2C_SlaveGetStatusFlags </td>
          <td>(</td>
          <td class="paramtype">I2C_Type *&#160;</td>
          <td class="paramname"><em>base</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">static</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>I2C base pointer </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>status flag, use status flag to AND <a class="el" href="group__i2c__driver.html#ga1f1337bbe9d0b184d9dcee31f9ebade2" title="I2C peripheral flags. ">_i2c_flags</a> to get the related status. </dd></dl>

</div>
</div>
<a class="anchor" id="ga545c1a43d8d49c4675de493d45a4063a"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">static void I2C_SlaveClearStatusFlags </td>
          <td>(</td>
          <td class="paramtype">I2C_Type *&#160;</td>
          <td class="paramname"><em>base</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>statusMask</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">static</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>The following status register flags can be cleared kI2C_ArbitrationLostFlag and kI2C_IntPendingFlag</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>I2C base pointer </td></tr>
    <tr><td class="paramname">statusMask</td><td>The status flag mask, defined in type i2c_status_flag_t. The parameter can be any combination of the following values: <ul>
<li>kI2C_IntPendingFlagFlag </li>
</ul>
</td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="ga577e094cc4d39b88ec5bbe49bc199c77"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void I2C_EnableInterrupts </td>
          <td>(</td>
          <td class="paramtype">I2C_Type *&#160;</td>
          <td class="paramname"><em>base</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>mask</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>I2C base pointer </td></tr>
    <tr><td class="paramname">mask</td><td>interrupt source The parameter can be combination of the following source if defined: <ul>
<li>kI2C_GlobalInterruptEnable </li>
<li>kI2C_StopDetectInterruptEnable/kI2C_StartDetectInterruptEnable </li>
<li>kI2C_SdaTimeoutInterruptEnable </li>
</ul>
</td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="ga9839c1fd49a0f62f42b0adfa74f62853"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void I2C_DisableInterrupts </td>
          <td>(</td>
          <td class="paramtype">I2C_Type *&#160;</td>
          <td class="paramname"><em>base</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>mask</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>I2C base pointer </td></tr>
    <tr><td class="paramname">mask</td><td>interrupt source The parameter can be combination of the following source if defined: <ul>
<li>kI2C_GlobalInterruptEnable </li>
<li>kI2C_StopDetectInterruptEnable/kI2C_StartDetectInterruptEnable </li>
<li>kI2C_SdaTimeoutInterruptEnable </li>
</ul>
</td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="gafeab1d5249a8b39c8d9e1a54a85c23f0"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void I2C_MasterSetBaudRate </td>
          <td>(</td>
          <td class="paramtype">I2C_Type *&#160;</td>
          <td class="paramname"><em>base</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>baudRate_Bps</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>srcClock_Hz</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>I2C base pointer </td></tr>
    <tr><td class="paramname">baudRate_Bps</td><td>the baud rate value in bps </td></tr>
    <tr><td class="paramname">srcClock_Hz</td><td>Source clock </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="ga7664234966e4162e952b6d57efcaa8a6"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">status_t I2C_MasterStart </td>
          <td>(</td>
          <td class="paramtype">I2C_Type *&#160;</td>
          <td class="paramname"><em>base</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint8_t&#160;</td>
          <td class="paramname"><em>address</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="group__i2c__driver.html#gab49c827b45635206f06e5737606e4611">i2c_direction_t</a>&#160;</td>
          <td class="paramname"><em>direction</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">
<p>This function is used to initiate a new master mode transfer by sending the START signal. The slave address is sent following the I2C START signal.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>I2C peripheral base pointer </td></tr>
    <tr><td class="paramname">address</td><td>7-bit slave device address. </td></tr>
    <tr><td class="paramname">direction</td><td>Master transfer directions(transmit/receive). </td></tr>
  </table>
  </dd>
</dl>
<dl class="retval"><dt>Return values</dt><dd>
  <table class="retval">
    <tr><td class="paramname">kStatus_Success</td><td>Successfully send the start signal. </td></tr>
    <tr><td class="paramname">kStatus_I2C_Busy</td><td>Current bus is busy. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="gaf46a8cc094fc18c6cadea8de71448723"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">status_t I2C_MasterStop </td>
          <td>(</td>
          <td class="paramtype">I2C_Type *&#160;</td>
          <td class="paramname"><em>base</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">
<dl class="retval"><dt>Return values</dt><dd>
  <table class="retval">
    <tr><td class="paramname">kStatus_Success</td><td>Successfully send the stop signal. </td></tr>
    <tr><td class="paramname">kStatus_I2C_Timeout</td><td>Send stop signal failed, timeout. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="ga42ff265d25e713326c7d152adf350147"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">status_t I2C_MasterRepeatedStart </td>
          <td>(</td>
          <td class="paramtype">I2C_Type *&#160;</td>
          <td class="paramname"><em>base</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint8_t&#160;</td>
          <td class="paramname"><em>address</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="group__i2c__driver.html#gab49c827b45635206f06e5737606e4611">i2c_direction_t</a>&#160;</td>
          <td class="paramname"><em>direction</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>I2C peripheral base pointer </td></tr>
    <tr><td class="paramname">address</td><td>7-bit slave device address. </td></tr>
    <tr><td class="paramname">direction</td><td>Master transfer directions(transmit/receive). </td></tr>
  </table>
  </dd>
</dl>
<dl class="retval"><dt>Return values</dt><dd>
  <table class="retval">
    <tr><td class="paramname">kStatus_Success</td><td>Successfully send the start signal. </td></tr>
    <tr><td class="paramname">kStatus_I2C_Busy</td><td>Current bus is busy but not occupied by current I2C master. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="gac4e1a954243aa852cb4d358e90091efd"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">status_t I2C_MasterWriteBlocking </td>
          <td>(</td>
          <td class="paramtype">I2C_Type *&#160;</td>
          <td class="paramname"><em>base</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const uint8_t *&#160;</td>
          <td class="paramname"><em>txBuff</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>txSize</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>flags</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>The I2C peripheral base pointer. </td></tr>
    <tr><td class="paramname">txBuff</td><td>The pointer to the data to be transferred. </td></tr>
    <tr><td class="paramname">txSize</td><td>The length in bytes of the data to be transferred. </td></tr>
    <tr><td class="paramname">flags</td><td>Transfer control flag to decide whether need to send a stop, use kI2C_TransferDefaultFlag to issue a stop and kI2C_TransferNoStop to not send a stop. </td></tr>
  </table>
  </dd>
</dl>
<dl class="retval"><dt>Return values</dt><dd>
  <table class="retval">
    <tr><td class="paramname">kStatus_Success</td><td>Successfully complete the data transmission. </td></tr>
    <tr><td class="paramname">kStatus_I2C_ArbitrationLost</td><td>Transfer error, arbitration lost. </td></tr>
    <tr><td class="paramname">kStataus_I2C_Nak</td><td>Transfer error, receive NAK during transfer. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="gaf77526f32a16109abf265dbb022a26ba"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">status_t I2C_MasterReadBlocking </td>
          <td>(</td>
          <td class="paramtype">I2C_Type *&#160;</td>
          <td class="paramname"><em>base</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint8_t *&#160;</td>
          <td class="paramname"><em>rxBuff</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>rxSize</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>flags</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">
<dl class="section note"><dt>Note</dt><dd>The I2C_MasterReadBlocking function stops the bus before reading the final byte. Without stopping the bus prior for the final read, the bus issues another read, resulting in garbage data being read into the data register.</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>I2C peripheral base pointer. </td></tr>
    <tr><td class="paramname">rxBuff</td><td>The pointer to the data to store the received data. </td></tr>
    <tr><td class="paramname">rxSize</td><td>The length in bytes of the data to be received. </td></tr>
    <tr><td class="paramname">flags</td><td>Transfer control flag to decide whether need to send a stop, use kI2C_TransferDefaultFlag to issue a stop and kI2C_TransferNoStop to not send a stop. </td></tr>
  </table>
  </dd>
</dl>
<dl class="retval"><dt>Return values</dt><dd>
  <table class="retval">
    <tr><td class="paramname">kStatus_Success</td><td>Successfully complete the data transmission. </td></tr>
    <tr><td class="paramname">kStatus_I2C_Timeout</td><td>Send stop signal failed, timeout. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="ga280404c6b1ede542f2c1c20bd382869c"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">status_t I2C_SlaveWriteBlocking </td>
          <td>(</td>
          <td class="paramtype">I2C_Type *&#160;</td>
          <td class="paramname"><em>base</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const uint8_t *&#160;</td>
          <td class="paramname"><em>txBuff</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>txSize</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>The I2C peripheral base pointer. </td></tr>
    <tr><td class="paramname">txBuff</td><td>The pointer to the data to be transferred. </td></tr>
    <tr><td class="paramname">txSize</td><td>The length in bytes of the data to be transferred. </td></tr>
  </table>
  </dd>
</dl>
<dl class="retval"><dt>Return values</dt><dd>
  <table class="retval">
    <tr><td class="paramname">kStatus_Success</td><td>Successfully complete the data transmission. </td></tr>
    <tr><td class="paramname">kStatus_I2C_ArbitrationLost</td><td>Transfer error, arbitration lost. </td></tr>
    <tr><td class="paramname">kStataus_I2C_Nak</td><td>Transfer error, receive NAK during transfer. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="gaf7409e50ffd9b260744c13863c7a3987"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void I2C_SlaveReadBlocking </td>
          <td>(</td>
          <td class="paramtype">I2C_Type *&#160;</td>
          <td class="paramname"><em>base</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint8_t *&#160;</td>
          <td class="paramname"><em>rxBuff</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>rxSize</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>I2C peripheral base pointer. </td></tr>
    <tr><td class="paramname">rxBuff</td><td>The pointer to the data to store the received data. </td></tr>
    <tr><td class="paramname">rxSize</td><td>The length in bytes of the data to be received. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="ga35cae3a5b4aa50ce8db28e3eb703a027"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">status_t I2C_MasterTransferBlocking </td>
          <td>(</td>
          <td class="paramtype">I2C_Type *&#160;</td>
          <td class="paramname"><em>base</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="group__i2c__driver.html#structi2c__master__transfer__t">i2c_master_transfer_t</a> *&#160;</td>
          <td class="paramname"><em>xfer</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">
<dl class="section note"><dt>Note</dt><dd>The API does not return until the transfer succeeds or fails due to arbitration lost or receiving a NAK.</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>I2C peripheral base address. </td></tr>
    <tr><td class="paramname">xfer</td><td>Pointer to the transfer structure. </td></tr>
  </table>
  </dd>
</dl>
<dl class="retval"><dt>Return values</dt><dd>
  <table class="retval">
    <tr><td class="paramname">kStatus_Success</td><td>Successfully complete the data transmission. </td></tr>
    <tr><td class="paramname">kStatus_I2C_Busy</td><td>Previous transmission still not finished. </td></tr>
    <tr><td class="paramname">kStatus_I2C_Timeout</td><td>Transfer error, wait signal timeout. </td></tr>
    <tr><td class="paramname">kStatus_I2C_ArbitrationLost</td><td>Transfer error, arbitration lost. </td></tr>
    <tr><td class="paramname">kStataus_I2C_Nak</td><td>Transfer error, receive NAK during transfer. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="ga31e3de02b57801c6896e6045c4a31268"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void I2C_MasterTransferCreateHandle </td>
          <td>(</td>
          <td class="paramtype">I2C_Type *&#160;</td>
          <td class="paramname"><em>base</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">i2c_master_handle_t *&#160;</td>
          <td class="paramname"><em>handle</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="group__i2c__driver.html#ga1c6e059706357c744c165ce7ecd1c185">i2c_master_transfer_callback_t</a>&#160;</td>
          <td class="paramname"><em>callback</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">void *&#160;</td>
          <td class="paramname"><em>userData</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>I2C base pointer. </td></tr>
    <tr><td class="paramname">handle</td><td>pointer to i2c_master_handle_t structure to store the transfer state. </td></tr>
    <tr><td class="paramname">callback</td><td>pointer to user callback function. </td></tr>
    <tr><td class="paramname">userData</td><td>user parameter passed to the callback function. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="gac7f76a04b6f6873c52ad176d58901fe9"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">status_t I2C_MasterTransferNonBlocking </td>
          <td>(</td>
          <td class="paramtype">I2C_Type *&#160;</td>
          <td class="paramname"><em>base</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">i2c_master_handle_t *&#160;</td>
          <td class="paramname"><em>handle</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="group__i2c__driver.html#structi2c__master__transfer__t">i2c_master_transfer_t</a> *&#160;</td>
          <td class="paramname"><em>xfer</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">
<dl class="section note"><dt>Note</dt><dd>Calling the API returns immediately after transfer initiates. The user needs to call I2C_MasterGetTransferCount to poll the transfer status to check whether the transfer is finished. If the return status is not kStatus_I2C_Busy, the transfer is finished.</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>I2C base pointer. </td></tr>
    <tr><td class="paramname">handle</td><td>pointer to i2c_master_handle_t structure which stores the transfer state. </td></tr>
    <tr><td class="paramname">xfer</td><td>pointer to <a class="el" href="group__i2c__driver.html#structi2c__master__transfer__t" title="I2C master transfer structure. ">i2c_master_transfer_t</a> structure. </td></tr>
  </table>
  </dd>
</dl>
<dl class="retval"><dt>Return values</dt><dd>
  <table class="retval">
    <tr><td class="paramname">kStatus_Success</td><td>Successfully start the data transmission. </td></tr>
    <tr><td class="paramname">kStatus_I2C_Busy</td><td>Previous transmission still not finished. </td></tr>
    <tr><td class="paramname">kStatus_I2C_Timeout</td><td>Transfer error, wait signal timeout. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="ga7d720842e68161d2d52d56d119f20665"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">status_t I2C_MasterTransferGetCount </td>
          <td>(</td>
          <td class="paramtype">I2C_Type *&#160;</td>
          <td class="paramname"><em>base</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">i2c_master_handle_t *&#160;</td>
          <td class="paramname"><em>handle</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t *&#160;</td>
          <td class="paramname"><em>count</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>I2C base pointer. </td></tr>
    <tr><td class="paramname">handle</td><td>pointer to i2c_master_handle_t structure which stores the transfer state. </td></tr>
    <tr><td class="paramname">count</td><td>Number of bytes transferred so far by the non-blocking transaction. </td></tr>
  </table>
  </dd>
</dl>
<dl class="retval"><dt>Return values</dt><dd>
  <table class="retval">
    <tr><td class="paramname">kStatus_InvalidArgument</td><td>count is Invalid. </td></tr>
    <tr><td class="paramname">kStatus_Success</td><td>Successfully return the count. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="ga77c9f9c8bc0fe71bbcd9d479f51f8044"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void I2C_MasterTransferAbort </td>
          <td>(</td>
          <td class="paramtype">I2C_Type *&#160;</td>
          <td class="paramname"><em>base</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">i2c_master_handle_t *&#160;</td>
          <td class="paramname"><em>handle</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">
<dl class="section note"><dt>Note</dt><dd>This API can be called at any time when an interrupt non-blocking transfer initiates to abort the transfer early.</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>I2C base pointer. </td></tr>
    <tr><td class="paramname">handle</td><td>pointer to i2c_master_handle_t structure which stores the transfer state </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="gad091cd1857d2bd8ce64583739b3a35d5"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void I2C_MasterTransferHandleIRQ </td>
          <td>(</td>
          <td class="paramtype">I2C_Type *&#160;</td>
          <td class="paramname"><em>base</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">void *&#160;</td>
          <td class="paramname"><em>i2cHandle</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>I2C base pointer. </td></tr>
    <tr><td class="paramname">i2cHandle</td><td>pointer to i2c_master_handle_t structure. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="gac9b90f575d92ff8ad3cc350a5c8ad1b9"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void I2C_SlaveTransferCreateHandle </td>
          <td>(</td>
          <td class="paramtype">I2C_Type *&#160;</td>
          <td class="paramname"><em>base</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">i2c_slave_handle_t *&#160;</td>
          <td class="paramname"><em>handle</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="group__i2c__driver.html#ga974310ded85af5ef341811d542db650c">i2c_slave_transfer_callback_t</a>&#160;</td>
          <td class="paramname"><em>callback</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">void *&#160;</td>
          <td class="paramname"><em>userData</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>I2C base pointer. </td></tr>
    <tr><td class="paramname">handle</td><td>pointer to i2c_slave_handle_t structure to store the transfer state. </td></tr>
    <tr><td class="paramname">callback</td><td>pointer to user callback function. </td></tr>
    <tr><td class="paramname">userData</td><td>user parameter passed to the callback function. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="gaa387d81ea08a9d4b39cfeb3dfec505f7"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">status_t I2C_SlaveTransferNonBlocking </td>
          <td>(</td>
          <td class="paramtype">I2C_Type *&#160;</td>
          <td class="paramname"><em>base</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">i2c_slave_handle_t *&#160;</td>
          <td class="paramname"><em>handle</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>eventMask</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">
<p>Call this API after calling the <a class="el" href="group__i2c__driver.html#gae6e155a5aadb43d527418e2965e39123" title="Initializes the I2C peripheral. ">I2C_SlaveInit()</a> and <a class="el" href="group__i2c__driver.html#gac9b90f575d92ff8ad3cc350a5c8ad1b9" title="Initializes the I2C handle which is used in transactional functions. ">I2C_SlaveTransferCreateHandle()</a> to start processing transactions driven by an I2C master. The slave monitors the I2C bus and passes events to the callback that was passed into the call to <a class="el" href="group__i2c__driver.html#gac9b90f575d92ff8ad3cc350a5c8ad1b9" title="Initializes the I2C handle which is used in transactional functions. ">I2C_SlaveTransferCreateHandle()</a>. The callback is always invoked from the interrupt context.</p>
<p>The set of events received by the callback is customizable. To do so, set the <em>eventMask</em> parameter to the OR'd combination of <a class="el" href="group__i2c__driver.html#gac53e5c96a2eed1b5a95b7d84be48f4ac" title="Set of events sent to the callback for nonblocking slave transfers. ">i2c_slave_transfer_event_t</a> enumerators for the events you wish to receive. The <a class="el" href="group__i2c__driver.html#ggac53e5c96a2eed1b5a95b7d84be48f4aca2f85039a57379838909876a1d509b7aa" title="A callback is requested to provide data to transmit (slave-transmitter role). ">kI2C_SlaveTransmitEvent</a> and #kLPI2C_SlaveReceiveEvent events are always enabled and do not need to be included in the mask. Alternatively, pass 0 to get a default set of only the transmit and receive events that are always enabled. In addition, the <a class="el" href="group__i2c__driver.html#ggac53e5c96a2eed1b5a95b7d84be48f4aca94b030ebdac378a84961893ae567bfbc" title="A bit mask of all available events. ">kI2C_SlaveAllEvents</a> constant is provided as a convenient way to enable all events.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>The I2C peripheral base address. </td></tr>
    <tr><td class="paramname">handle</td><td>Pointer to #i2c_slave_handle_t structure which stores the transfer state. </td></tr>
    <tr><td class="paramname">eventMask</td><td>Bit mask formed by OR'ing together <a class="el" href="group__i2c__driver.html#gac53e5c96a2eed1b5a95b7d84be48f4ac" title="Set of events sent to the callback for nonblocking slave transfers. ">i2c_slave_transfer_event_t</a> enumerators to specify which events to send to the callback. Other accepted values are 0 to get a default set of only the transmit and receive events, and <a class="el" href="group__i2c__driver.html#ggac53e5c96a2eed1b5a95b7d84be48f4aca94b030ebdac378a84961893ae567bfbc" title="A bit mask of all available events. ">kI2C_SlaveAllEvents</a> to enable all events.</td></tr>
  </table>
  </dd>
</dl>
<dl class="retval"><dt>Return values</dt><dd>
  <table class="retval">
    <tr><td class="paramname">#kStatus_Success</td><td>Slave transfers were successfully started. </td></tr>
    <tr><td class="paramname"><a class="el" href="group__i2c__driver.html#gga7cc91c89125c25a88e463a9e8550b284a49091894b590d7e479605bf113918952" title="I2C is busy with current transfer. ">kStatus_I2C_Busy</a></td><td>Slave transfers have already been started on this handle. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="ga5ae9f5e6e854d14d33ba3029128bd6f0"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void I2C_SlaveTransferAbort </td>
          <td>(</td>
          <td class="paramtype">I2C_Type *&#160;</td>
          <td class="paramname"><em>base</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">i2c_slave_handle_t *&#160;</td>
          <td class="paramname"><em>handle</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">
<dl class="section note"><dt>Note</dt><dd>This API can be called at any time to stop slave for handling the bus events.</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>I2C base pointer. </td></tr>
    <tr><td class="paramname">handle</td><td>pointer to i2c_slave_handle_t structure which stores the transfer state. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="gabf38a498bd3527ea0b7cc947ae71e17e"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">status_t I2C_SlaveTransferGetCount </td>
          <td>(</td>
          <td class="paramtype">I2C_Type *&#160;</td>
          <td class="paramname"><em>base</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">i2c_slave_handle_t *&#160;</td>
          <td class="paramname"><em>handle</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t *&#160;</td>
          <td class="paramname"><em>count</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>I2C base pointer. </td></tr>
    <tr><td class="paramname">handle</td><td>pointer to i2c_slave_handle_t structure. </td></tr>
    <tr><td class="paramname">count</td><td>Number of bytes transferred so far by the non-blocking transaction. </td></tr>
  </table>
  </dd>
</dl>
<dl class="retval"><dt>Return values</dt><dd>
  <table class="retval">
    <tr><td class="paramname">kStatus_InvalidArgument</td><td>count is Invalid. </td></tr>
    <tr><td class="paramname">kStatus_Success</td><td>Successfully return the count. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="ga097c0b20503381de44cccba311dcf236"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void I2C_SlaveTransferHandleIRQ </td>
          <td>(</td>
          <td class="paramtype">I2C_Type *&#160;</td>
          <td class="paramname"><em>base</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">void *&#160;</td>
          <td class="paramname"><em>i2cHandle</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>I2C base pointer. </td></tr>
    <tr><td class="paramname">i2cHandle</td><td>pointer to i2c_slave_handle_t structure which stores the transfer state </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
</div><!-- contents -->
</div><!-- doc-content -->
<!-- HTML footer for doxygen 1.8.5-->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  <ul class="foot">
    <li class="footer">&copy; 2016 NXP Semiconductors. All rights reserved.
    </li>
  </ul>
</div>
</body>
</html>
